Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to find the version of your PowerShell

📅 2012-Mar-02 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ powershell, version ⬩ 📚 Archive

How do you find out the version of PowerShell you are using? This information can be found from the PSVersionTable variable. It holds the versions of the various components of PowerShell.

$ $PSVersionTable
Name                           Value
----                           -----
CLRVersion                     2.0.50727.5448
BuildVersion                   6.1.7601.17514
PSVersion                      2.0
WSManStackVersion              2.0
PSCompatibleVersions           {1.0, 2.0}
SerializationVersion           1.1.0.1
PSRemotingProtocolVersion      2.1

To find just the version of the shell component:

$ $PSVersionTable.PSVersion
Major  Minor  Build  Revision
-----  -----  -----  --------
2      0      -1     -1

So, I am using version 2.0 😊

Tried with: PowerShell 2.0


© 2022 Ashwin Nanjappa • All writing under CC BY-SA license • 🐘 @codeyarns@hachyderm.io📧