aboutsummaryrefslogtreecommitdiff
path: root/bin/install.sh
diff options
context:
space:
mode:
authorJakob Stendahl <jakob.stendahl@outlook.com>2018-10-18 16:29:48 +0200
committerJakob Stendahl <jakob.stendahl@outlook.com>2018-10-18 16:29:48 +0200
commit0c0561b98528d01faf0d7d6ab5a9324609284aaf (patch)
tree43c1d16db2d1522cf3bf6c0e9e96011f99b7139f /bin/install.sh
parent4a4a950ea94d460c9afd3d8062b377c18e977963 (diff)
downloadLuxcena-Neo-0c0561b98528d01faf0d7d6ab5a9324609284aaf.tar.gz
Luxcena-Neo-0c0561b98528d01faf0d7d6ab5a9324609284aaf.zip
:bug: Fix syntax, check function success with it's own if
Diffstat (limited to 'bin/install.sh')
-rwxr-xr-xbin/install.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/install.sh b/bin/install.sh
index 289f48e..08f160b 100755
--- a/bin/install.sh
+++ b/bin/install.sh
@@ -115,8 +115,10 @@ printf '%s\n' " - Running npm i..."
tput sgr0
tput sc
export NODE_ENV=production || { printf "\n\nInstall failed.\n"; exit 1; }
-sudo runuser -l $username -c 'npm --prefix ~/install/src install ~/install/src --only=production || { printf "\n\nInstall failed.\n"; exit 1; }' # This is probably a bit overkill to have --only=... but better safe than sorry?
-if [ $? -eq 0 ]; then
+sudo runuser -l $username -c 'npm --prefix ~/install/src install ~/install/src --only=production' # This is probably a bit overkill to have --only=... but better safe than sorry?
+if [ $? -ne 0 ]; then
+ printf "\n\nInstall failed.\n"
+ exit 1
fi
tput rc; tput ed