diff options
author | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2016-05-12 10:20:29 +0100 |
---|---|---|
committer | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2016-05-12 10:20:29 +0100 |
commit | 4972e30733a4650b100f72e11a91d4022db98733 (patch) | |
tree | e92102b7a516137be1af4918b6a4dbe8391c1efa /install_dependencies.sh | |
parent | 895962965842d25b145b646c10888bdce9ddacd6 (diff) | |
download | ybd-4972e30733a4650b100f72e11a91d4022db98733.tar.gz |
Check for installation success
Diffstat (limited to 'install_dependencies.sh')
-rwxr-xr-x | install_dependencies.sh | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/install_dependencies.sh b/install_dependencies.sh index 41f0126..7d29bc5 100755 --- a/install_dependencies.sh +++ b/install_dependencies.sh @@ -28,6 +28,10 @@ which apt-get 2>&1 > /dev/null if [ $? -eq 0 ]; then sudo apt-get -qq update sudo apt-get -qq install build-essential gawk git m4 wget + if [ $? -ne 0 ]; then + echo "Install failed" + exit 1 + fi installed=true fi @@ -35,13 +39,21 @@ fi which dnf 2>&1 > /dev/null if [ $? -eq 0 ] && [ $installed = false ]; then sudo dnf install -y which make automake gcc gcc-c++ gawk git m4 wget + if [ $? -ne 0 ]; then + echo "Install failed" + exit 1 + fi installed=true fi # install for aws which yum 2>&1 > /dev/null if [ $? -eq 0 ] && [ $installed = false ]; then - sudo yum install -y which make automake gcc gcc-c++ gawk git m4 wget + sudo yum install -y which make automake gcc gcc-c++ gawk git m4 wget + if [ $? -ne 0 ]; then + echo "Install failed" + exit 1 + fi installed=true fi |