From 287b2010eac69a5e0e3d5db50b3488dc59cfdc4a Mon Sep 17 00:00:00 2001 From: Stoabrogga <38475780+Stoabrogga@users.noreply.github.com> Date: Sat, 4 Aug 2018 22:50:16 +0000 Subject: [PATCH 1/3] exit compiler script if any statement returns non-zero exit code --- apps/compiler/compiler.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apps/compiler/compiler.sh b/apps/compiler/compiler.sh index 388ad41a3..168323ea4 100755 --- a/apps/compiler/compiler.sh +++ b/apps/compiler/compiler.sh @@ -1,5 +1,7 @@ #!/usr/bin/env bash +set -e + CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" source "$CURRENT_PATH/includes/includes.sh" From 5278e96acad6ba67548c2ccd1ec119c5ef5b0901 Mon Sep 17 00:00:00 2001 From: Stoabrogga <38475780+Stoabrogga@users.noreply.github.com> Date: Sun, 5 Aug 2018 04:55:47 +0000 Subject: [PATCH 2/3] ignore exit code of 'make clean' as it won't find a Makefile if called as first action (which is the case for "compiler all") --- apps/compiler/includes/functions.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/compiler/includes/functions.sh b/apps/compiler/includes/functions.sh index 92d2d7bdc..e0f5560b1 100644 --- a/apps/compiler/includes/functions.sh +++ b/apps/compiler/includes/functions.sh @@ -6,8 +6,8 @@ function comp_clean() { cd $BUILDPATH - make -f Makefile clean - make clean + make -f Makefile clean || true + make clean || true find -iname '*cmake*' -not -name CMakeLists.txt -exec rm -rf {} \+ cd $CWD @@ -69,4 +69,4 @@ function comp_build() { function comp_all() { comp_clean comp_build -} \ No newline at end of file +} From c3ecdf751d55f7af7ea7f1df3683ed27d7061739 Mon Sep 17 00:00:00 2001 From: Stoabrogga <38475780+Stoabrogga@users.noreply.github.com> Date: Sun, 5 Aug 2018 15:10:03 +0000 Subject: [PATCH 3/3] add "set -e" also to script "db_assembler.sh" --- apps/db_assembler/db_assembler.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apps/db_assembler/db_assembler.sh b/apps/db_assembler/db_assembler.sh index e1e1de240..eaa6b1678 100644 --- a/apps/db_assembler/db_assembler.sh +++ b/apps/db_assembler/db_assembler.sh @@ -1,5 +1,7 @@ #!/usr/bin/env bash +set -e + CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" source "$CURRENT_PATH/includes/includes.sh"