Skip to content

Latest commit

 

History

History
51 lines (31 loc) · 1.09 KB

Test-IsPSWindows.md

File metadata and controls

51 lines (31 loc) · 1.09 KB
external help file Module Name online version schema
PSScriptTools-help.xml
PSScriptTools
2.0.0

Test-IsPSWindows

SYNOPSIS

Test if running PowerShell on a Windows platform.

SYNTAX

Test-IsPSWindows [<CommonParameters>]

DESCRIPTION

PowerShell Core introduced the $IsWindows variable. However, it is not available on Windows PowerShell. Use this command to perform a simple test if the computer is either running Windows or using the Desktop PSEdition.

EXAMPLES

Example 1

PS C:\> Test-IsPSWindows
True

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

OUTPUTS

System.Boolean

NOTES

Learn more about PowerShell: http://jdhitsolutions.com/blog/essential-powershell-resources/

RELATED LINKS