CI: Run all style/lint checks before failing

Even if we get warnings from the first lint check, we probably want to
see the warnings from later lint checks too, to reduce the number of
round-trips.

Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
Simon McVittie 2024-02-07 13:00:45 +00:00 committed by Philip Withnall
parent a7702505e0
commit e87db7dbf2

View File

@ -128,8 +128,10 @@ style-check-advisory:
stage: style-check
allow_failure: true
script:
- .gitlab-ci/run-style-check-diff.sh
- .gitlab-ci/run-check-todos.sh
- failed=
- .gitlab-ci/run-style-check-diff.sh || failed=1
- .gitlab-ci/run-check-todos.sh || failed=1
- test -z "$failed"
sh-and-py-check:
extends:
@ -139,9 +141,11 @@ sh-and-py-check:
stage: style-check
allow_failure: false
script:
- tests/shellcheck.sh
- tests/black.sh
- tests/flake8.sh
- failed=
- tests/shellcheck.sh || failed=1
- tests/black.sh || failed=1
- tests/flake8.sh || failed=1
- test -z "$failed"
variables:
LINT_WARNINGS_ARE_ERRORS: '1'
only: