mirror of
https://github.com/PowerShell/PowerShell.git
synced 2024-11-27 11:56:14 +08:00
Handle package download failure
This commit is contained in:
parent
fc2e4e0e23
commit
363657717c
@ -70,6 +70,11 @@ packageuri=$(curl -s -i -H 'Accept: application/octet-stream' "https://api.githu
|
||||
grep location | sed 's/location: //g')
|
||||
curl -C - -o "$package" ${packageuri%$'\r'}
|
||||
|
||||
if [[ ! -r "$package" ]]; then
|
||||
echo "ERROR: $package failed to download! Aborting..." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Installs PowerShell package
|
||||
case "$OSTYPE" in
|
||||
linux*)
|
||||
|
Loading…
Reference in New Issue
Block a user