Getting the PowerShell Version

Posted by Johan Cyprich on 04 Aug 2010 | Tagged as: Programming

To find out which version of PowerShell is installed in your computer, you need to do more than just run it. When you start the command line interface, your lead to believe that version 1.0 is installed from the directory location displayed in the dialog box.

The text in the dialog box shows C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe, which would make it seem like you were running version 1.0. The best way to determine which version is installed is to run the PowerShell command line interface and execute the following command:

    $Host.Version

This will give you the major and minor versions, along with the build and revision.

image



Tweet This Tweet This Post!

Related posts:
    Upgrading to Windows PowerShell 2.0 from Community Technology Preview
    PowerShell: A Better CMD.EXE
    Setting Permissions to Run PowerShell Scripts
    pscoder: PowerShell plugin for Eclipse

Share this post:

del.icio.us:Getting the PowerShell Version digg:Getting the PowerShell Version spurl:Getting the PowerShell Version wists:Getting the PowerShell Version simpy:Getting the PowerShell Version newsvine:Getting the PowerShell Version blinklist:Getting the PowerShell Version furl:Getting the PowerShell Version reddit:Getting the PowerShell Version fark:Getting the PowerShell Version blogmarks:Getting the PowerShell Version Y!:Getting the PowerShell Version smarking:Getting the PowerShell Version magnolia:Getting the PowerShell Version segnalo:Getting the PowerShell Version gifttagging:Getting the PowerShell Version

Follow Me:

Did you find this post interesting and useful? You can keep up to date on this blog by subscribing to my RSS feed, or you can have new posts sent to you by e-mail. You can also follow me on Twitter.


Trackback This Post | Subscribe to the comments through RSS Feed

Leave a Reply

CommentLuv badge