Add custom python problem matcher for pylint and yapf

This commit is contained in:
Jean-Michel Picod
2020-02-27 18:39:44 +01:00
parent fb98d1bfde
commit d69b40f2cf
2 changed files with 56 additions and 3 deletions

View File

@@ -26,7 +26,10 @@ jobs:
- name: Test code with pylint
run: |
pip install pylint
pylint --rcfile=.pylintrc --score=n `find . ! -path "./third_party/*" -type f -name '*.py'`
./setup.sh
echo ::add-matcher::./.github/python_matcher.json
find . -type f -name '*.py' -exec echo PYLINT:\{\} \; -exec pylint --rcfile=.pylintrc --score=n \{\} \;
#find . ! -path "./third_party/*" -type f -name '*.py' -exec echo PYLINT:\{\} \; -exec pylint --rcfile=.pylintrc --score=n \{\} \;
yapf:
runs-on: ubuntu-18.04
@@ -39,6 +42,9 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
pip install yapf
pip install yapf tockloader
- name: Test code formatting with yapf
run: yapf --style=chromium --recursive --exclude third_party --diff .
run: |
./setup.sh
echo ::add-matcher::./.github/python_matcher.json
yapf --style=chromium --recursive --exclude third_party --diff .