Throw a fatal error if tflint --init fails

This commit is contained in:
Marco Ferrari 2022-10-04 17:15:18 +00:00 committed by Brett Logan
parent bf67bd6c01
commit 8607445fb4

View file

@ -527,11 +527,10 @@ function RunAdditionalInstalls() {
# Check the shell for errors #
##############################
if [ "${ERROR_CODE}" -ne 0 ]; then
# Error
warn "ERROR! Failed to run:[tflint --init] at location:[${WORKSPACE_PATH}]"
warn "BUILD_CMD:[${BUILD_CMD}]"
fatal "ERROR! Failed to run:[tflint --init] at location:[${WORKSPACE_PATH}]. BUILD_CMD:[${BUILD_CMD}]"
else
info "Successfully ran:[tflint --init] in workspace:[${WORKSPACE_PATH}]"
debug "BUILD_CMD:[${BUILD_CMD}]"
fi
fi
}