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.
1 parent c55af5d commit f25fb3cCopy full SHA for f25fb3c
.github/workflows/pylint.yml
@@ -21,4 +21,19 @@ jobs:
21
pip install pylint
22
- name: Analysing the code with pylint
23
run: |
24
- pylint $(git ls-files '*.py')
+ pylint $(git ls-files '*.py') pylint-report.txt || true
25
+
26
+ - name: Analyze Pylint Score
27
+ id: pylint-score
28
+ run: |
29
+ SCORE=$(tail -n 2 pylint-report.txt | grep -oE "[0-9]+\.[0-9]+(?=/10)")
30
+ echo "Pylint score: $SCORE"
31
+ echo "score=$SCORE" >> $GITHUB_ENV
32
+ - name: Check Pylint score
33
34
+ if (( $(echo "$SCORE < 8.0" | bc -l) )); then
35
+ echo "Pylint score $SCORE is below the passing threshold of 8.0"
36
+ exit 1
37
+ fi
38
+ env:
39
+ SCORE: ${{ env.score }}
0 commit comments