We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents cd2b84e + 9496871 commit 348e682Copy full SHA for 348e682
.forgejo/workflows/yamllint.yml
@@ -21,10 +21,11 @@ jobs:
21
22
- name: Lint .yml files
23
run: |
24
- lint_output=$(find docker -name "*.yml" -exec yamllint -d "{extends: relaxed, rules: {line-length: {max: 120}}}" {} \;)
+ lint_output=$(find docker -name "*.yml" -exec yamllint --strict -d "{extends: relaxed, rules: {line-length: {max: 120}}}" {} \;)
25
26
- # Check if there are any issues
27
- if [[ -n "$lint_output" ]]; then
28
- echo "$lint_output"
+ # Check if there are any warnings or errors in the output
+ echo "$lint_output"
+ if echo "$lint_output" | grep -q -E "error|warning"; then
29
+ echo "YAML linting failed due to errors or warnings."
30
exit 1
31
fi
0 commit comments