summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorTitanSnow <[email protected]>2017-04-20 11:46:28 +0800
committerTitanSnow <[email protected]>2017-04-20 11:50:16 +0800
commit440edf5ffcdcf344fe30638fc31795701610fd55 (patch)
tree392b9e933a3eefef8108bae3b662de4fabc8839c /scripts
parente15f9f9877ccca28979d66aaec08a8ab36da6f9f (diff)
set erroraction to stop
Diffstat (limited to 'scripts')
-rw-r--r--scripts/get.ps14
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/get.ps1 b/scripts/get.ps1
index 43e834f24..734c61bc5 100644
--- a/scripts/get.ps1
+++ b/scripts/get.ps1
@@ -3,8 +3,8 @@
# Invoke-Expression (Invoke-Webrequest <my location> -UseBasicParsing).Content
$ver='v2.1.3'
-Invoke-Webrequest "https://github.com/tboox/xmake/releases/download/$ver/xmake-$ver.exe" -OutFile "$pid-xmake-installer.exe"
-Start-Process -FilePath "$pid-xmake-installer.exe" -ArgumentList '/S /D=C:\xmake' -Wait
+Invoke-Webrequest "https://github.com/tboox/xmake/releases/download/$ver/xmake-$ver.exe" -OutFile "$pid-xmake-installer.exe" -ErrorAction Stop
+Start-Process -FilePath "$pid-xmake-installer.exe" -ArgumentList '/S /D=C:\xmake' -Wait -ErrorAction Stop
Remove-Item "$pid-xmake-installer.exe"
$env:Path+=";C:\xmake"
[Environment]::SetEnvironmentVariable("Path",[Environment]::GetEnvironmentVariable("Path",[System.EnvironmentVariableTarget]::User)+";C:\xmake",[System.EnvironmentVariableTarget]::User)