X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Fpipeline-linter.sh;h=fad1f72c3b340e0a91cd5eeaf0a83fe697d70efe;hb=refs%2Fchanges%2F68%2F72668%2F12;hp=8ed681d5bffa1adffc032099ef6e44ce3da3c754;hpb=dda5157a63d6d92115e36edda5cdcb35e399e6db;p=releng%2Fglobal-jjb.git diff --git a/shell/pipeline-linter.sh b/shell/pipeline-linter.sh index 8ed681d5..fad1f72c 100644 --- a/shell/pipeline-linter.sh +++ b/shell/pipeline-linter.sh @@ -18,8 +18,7 @@ JENKINS_VAL="$JENKINS_URL/pipeline-model-converter/validate" mapfile -t JENKINS_FILE_LIST < <(grep -lr "^pipeline\s*{" vars src Jenkinsfile*) exit_code=0 -for JENKINS_FILE in "${JENKINS_FILE_LIST[@]}" -do +for JENKINS_FILE in "${JENKINS_FILE_LIST[@]}"; do ret=$(curl --silent -X POST -H "$JENKINS_CRUMB" -F "jenkinsfile=<$JENKINS_FILE" "$JENKINS_VAL") if [[ $ret == *"Errors"* ]];then echo "ERROR: Linting error for $JENKINS_FILE"