Fixed curl statement to check return HEADERS.
This commit is contained in:
parent
19fdd54cdc
commit
c94f493915
20
bin/install
20
bin/install
@ -10,13 +10,17 @@ binary_url="https://${bucket_name}.s3.amazonaws.com/${tarball_name}"
|
|||||||
|
|
||||||
echo "Downloading binary: ${binary_url}"
|
echo "Downloading binary: ${binary_url}"
|
||||||
|
|
||||||
curl $binary_url > $tarball_name
|
curl --fail -I $binary_url
|
||||||
|
|
||||||
if test -e "${tarball_name}"; then
|
if test $? -eq 0; then
|
||||||
echo "Unpacking binary distribution"
|
curl $binary_url > $tarball_name
|
||||||
tar -xvzf $tarball_name
|
if test -e "${tarball_name}"; then
|
||||||
exit 0;
|
echo "Unpacking binary distribution"
|
||||||
else
|
tar -xvzf $tarball_name
|
||||||
echo "Prebuild binary could not be downloaded, building from source..."
|
if test $? -eq 0; then
|
||||||
./bin/build
|
exit 0
|
||||||
|
fi
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
echo "Prebuild binary could not be downloaded, building from source..."
|
||||||
|
./bin/build
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user