generated from martinthomson/internet-draft-template
-
Notifications
You must be signed in to change notification settings - Fork 15
45 lines (37 loc) · 982 Bytes
/
lint-python.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Lint Python
on:
push:
branches:
- main
paths:
- '.github/workflows/lint-python.yml'
- 'poc/**'
pull_request:
paths:
- '.github/workflows/lint-python.yml'
- 'poc/**'
jobs:
test:
name: "Check formatting"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install tools
run: pip install pyflakes autopep8 isort pylint
- name: Run pyflakes
working-directory: poc
run: pyflakes *.py vdaf_poc/*.py tests/*.py
- name: Run autopep8
working-directory: poc
run: autopep8 --diff --exit-code *.py vdaf_poc/*.py tests/*.py
- name: Run isort
working-directory: poc
run: isort --check .
- name: Run pylint
working-directory: poc
run: pylint --disable=all --enable=redefined-outer-name *.py vdaf_poc/*.py tests/*.py