[gjs: 2/3] CI: skip senseless lint tasks
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs: 2/3] CI: skip senseless lint tasks
- Date: Thu, 29 Mar 2018 04:21:39 +0000 (UTC)
commit 40115a693c8ea7209d471df9a6efad15ae2b9bdb
Author: Claudio André <claudioandre br gmail com>
Date: Wed Mar 28 14:38:17 2018 -0300
CI: skip senseless lint tasks
test/test-ci.sh | 27 +++++++++++++++++++++------
1 file changed, 21 insertions(+), 6 deletions(-)
---
diff --git a/test/test-ci.sh b/test/test-ci.sh
index f43e6e7..9278c93 100755
--- a/test/test-ci.sh
+++ b/test/test-ci.sh
@@ -27,6 +27,12 @@ function do_Set_Env(){
echo '-- Done --'
}
+function do_Done(){
+ # Done. De-initializes whatever is needed
+ echo
+ echo '-- FINISHED --'
+}
+
function do_Build_Package_Dependencies(){
echo
echo "-- Building Dependencies for $1 --"
@@ -58,6 +64,15 @@ function do_Show_Info(){
function do_Get_Upstream_Master(){
+ if [[ "$CI_BUILD_REF_SLUG" == "master" && "$CI_PROJECT_PATH_SLUG" == "gnome-gjs" ]]; then
+ echo '--------------------------------'
+ echo 'Running against upstream master'
+ echo "=> $1 Nothing to do"
+
+ do_Done
+ exit 0
+ fi
+
echo '--------------------------------'
echo 'Cloning upstream master'
@@ -205,7 +220,7 @@ elif [[ $1 == "CPPCHECK" && "$log_message" != *'[skip cppcheck]'* ]]; then
echo
# Get the code committed at upstream master
- do_Get_Upstream_Master
+ do_Get_Upstream_Master "cppCheck"
cppcheck --inline-suppr --enable=warning,performance,portability,information,missingInclude --force -q .
2>&1 | \
tee "$save_dir"/cppcheck/master-report.txt | sed -E 's/:[0-9]+]/:LINE]/' > /cwd/master-report.txt
echo
@@ -222,7 +237,7 @@ elif [[ $1 == "CPPLINT" && "$log_message" != *'[skip cpplint]'* ]]; then
echo
# Get the code committed at upstream master
- do_Get_Upstream_Master
+ do_Get_Upstream_Master "cppLint"
cpplint --quiet $(find . -name \*.cpp -or -name \*.c -or -name \*.h | sort) 2>&1 | \
tee "$save_dir"/cpplint/master-report.txt | sed -E 's/:[0-9]+:/:LINE:/' > /cwd/master-report.txt
echo
@@ -243,7 +258,7 @@ elif [[ $1 == "ESLINT" && "$log_message" != *'[skip eslint]'* ]]; then
echo
# Get the code committed at upstream master
- do_Get_Upstream_Master
+ do_Get_Upstream_Master "esLint"
cp "$save_dir"/.eslint* .
eslint examples installed-tests modules --format unix 2>&1 | \
tee "$save_dir"/eslint/master-report.txt | \
@@ -261,6 +276,6 @@ elif [[ $1 == "TOKEI" ]]; then
tokei . | tee "$save_dir"/tokei/report.txt
fi
-# Done
-echo
-echo '-- DONE --'
+
+# Releases stuff and finishes
+do_Done
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]