Added auto-annotation to both checks

This works based on telling github how to understand the flake8 output

# Conflicts:
#	.github/workflows/push-checks.yml
This commit is contained in:
Athanasius committed 2021-04-01 14:45:45 +01:00
1 parent 7e094df6c4
commit c69cc77682
3 files changed
+13 -95

No files matched your search

+9 -6
View File
@@ -9,8 +9,8 @@ name: Push-Checks
on:
push:
branches: [ main ]
branches: [ develop ]
jobs:
build:
@@ -27,16 +27,19 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest wheel
pip install wheel flake8 pytest
if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
- name: Setup flake8 annotations
uses: rbialon/flake8-annotations@v1
- name: Lint with flake8
env:
ROOT_SHA: ${{github.base_ref}}
run: |
DATA=$(jq --raw-output .before $GITHUB_EVENT_PATH)
DATA=$(jq .before $GITHUB_EVENT_PATH)
# stop the build if there are Python syntax errors or undefined names, ignore existing
git diff "$DATA" | flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --diff
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
git diff "$DATA" | flake8 . --count --exit-zero --statistics --diff
git diff "$DATA" | flake8 . --count --statistics --diff