Monday, April 25, 2016

Determine PowerShell Version

PowerShell Cmdlets and syntax will sometimes vary from version to version. Its nice to have an easy way to check what version of PowerShell is installed on a system.There are a couple of ways to to this:
> $PSVersionTable.PSVersion

Major  Minor  Build  Revision
-----  -----  -----  --------
5      0      10586  122


Alternatively, you can also use the Get-Host command:
> (get-host).version

Major  Minor  Build  Revision
-----  -----  -----  --------
5      0      10586  122

No comments:

Post a Comment