To set the PATH environment variable for your PowerShell profile you have to do the following:
- Make sure you have a folder called WindowsPowerShell in My Documents.
- Create a file called profile.ps1 in the new folder and open it.
- Copy the following into the new file:
$paths = @();
$paths += $env:PATH;
$paths += join-path (get-itemproperty "HKLM:SOFTWARE\Microsoft\Microsoft SDKs\Windows").CurrentInstallFolder "bin";
$paths += join-path (get-itemproperty "HKLM:SOFTWARE\Microsoft\.NETFramework").InstallRoot "v2.0.50727";
$env:PATH = [string]::Join(";", $paths);
- Close the file.
- Open a new PowerShell prompt.