How to get PowerShell 7 version in Windows 11

Configurare noua (How To)

Situatie

Finding your PowerShell version helps you know what PowerShell features you have access to.

Solutie

Pasi de urmat

To check your PowerShell 7 version on Windows 11, just open up PowerShell 7 and look at the very first line in the window. It prints the PowerShell version every time you open a new instance.

If for some reason that doesn’t work, you can always use the PowerShell version command we discussed previously to get your version information. Enter the following command into PowerShell:

$PSVersionTable

Get PowerShell Version with the get-host Command

To use the get-host command to check your PowerShell version, open up any version of PowerShell, then enter:

get-host

Find PowerShell Version Using the $Host variable

The $host variable is automatically set when you open PowerShell, all we need to do is query the version. Once again, open up PowerShell, then enter:

$host.version

You’ll see your version number displayed in a neat little table.

You can also just run $host if that is more to your preference, but it contains additional information that you may not care about, much like the get-host command.

Tip solutie

Permanent

Voteaza

(5 din 10 persoane apreciaza acest articol)

Despre Autor

Leave A Comment?