Fix Add-Path helper function and start using it in scripts

This function was broken and only added the latest addition to the
actual PATH.

Change-Id: Ida352c7b605c1b9748bb98e4f51ce68a765c3ce3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
Joni Jäntti
2017-09-04 13:25:44 +03:00
parent 4e1f4665c5
commit dbf737a5c0
4 changed files with 7 additions and 5 deletions

View File

@@ -59,8 +59,7 @@ echo "Chancing allowZip64 value to 'True'..."
echo "Remove $package..."
del $package
$oldPath = [System.Environment]::GetEnvironmentVariable('Path', 'Machine')
[Environment]::SetEnvironmentVariable("Path", $oldPath + ";C:\Python27;C:\Python27\Scripts", [EnvironmentVariableTarget]::Machine)
Add-Path "C:\Python27;C:\Python27\Scripts"
C:\Python27\python.exe -m ensurepip
# Install python virtual env