Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/workflows/linting.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: linting
on: pull_request

jobs:
checkLinting:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.base.sha }}
- uses: actions/checkout@v3
with:
ref: ${{ github.sha }}
- uses: actions/setup-python@v4
with:
python-version: 3.7.9
architecture: x86
- name: Install required Python packages
run: |
python -m pip install flake8~=3.7.7 flake8-tabs==2.1.0
- name: generate pull request diff
run: |
git diff -U0 ${{ github.event.pull_request.base.sha }} | Out-File -FilePath _lint.diff
- name: Run flake8
run: |
Get-Content -Path _lint.diff | python -Xutf8 -m flake8 --diff --config=tests/lint/flake8.ini