Get-Vale

Get-Vale

SYNOPSIS

Gets the command info for Vale installed in a workspace, user’s home folder, or on a machine.

SYNTAX

Get-Vale [<CommonParameters>]

DESCRIPTION

The Get-Vale cmdlet returns a System.Management.Automation.ApplicationInfo object for the vale binary if it’s available. It first checks for the vale application in the following order, returning the first discovered application:

  1. It checks the .vale folder in the current working directory.
  2. It walks the directory tree up from the current working directory, checking the .vale folder in each parent directory.
  3. It checks the .vale folder in the user’s home directory.
  4. It checks the folders listed in the PATH environment variable.

The cmdlet returns an error if it doesn’t find the vale application.

This cmdlet is a convenience helper for using Vale when installed to the workspace or user’s home directory, as with the Install-Vale cmdlet.

EXAMPLES

Example 1: Get Vale and show its version

$Vale = Get-Vale

& $Vale --version
vale version 2.22.0

PARAMETERS

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

None

This cmdlet doesn’t support any pipeline input.

OUTPUTS

ValeApplicationInfo

This cmdlet returns a ValeApplicationInfo object, representing the same information as the System.Management.Automation.ApplicationInfo type but with the Version property correctly reflecting Vale’s version.

NOTES

Install-Vale

Last modified March 28, 2023: (GH-91) Add `Install-Vale` command (1b38ebc)