Skip to content

Test-ChocolateyInstall

SYNOPSIS

Test if the Chocolatey Software is installed.

SYNTAX

Test-ChocolateyInstall [[-InstallDir] <String>] [<CommonParameters>]

DESCRIPTION

To test whether the Chocolatey Software is installed, it first look for the Command choco.exe. It then check if it's installed in the InstallDir path, if provided.

EXAMPLES

EXAMPLE 1

Test-ChocolateyInstall #Test whether the Chocolatey Software is installed

PARAMETERS

-InstallDir

To ensure the software is installed in the given directory. If not specified, it will only test if the commadn choco.exe is available.

Type: System.String
Parameter Sets: (All)
Aliases:

Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

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

OUTPUTS

System.Boolean

NOTES

General notes

Back to top