File tree Expand file tree Collapse file tree 2 files changed +10
-24
lines changed Expand file tree Collapse file tree 2 files changed +10
-24
lines changed Original file line number Diff line number Diff line change 1+ name : Lint
2+
3+ on : [push, pull_request]
4+
5+ jobs :
6+ lint :
7+ runs-on : ubuntu-latest
8+ steps :
9+ - uses : actions/checkout@v2
10+ - uses : psf/black@stable
Original file line number Diff line number Diff line change 1010 - cron : " 0 1 * * *"
1111 workflow_dispatch :
1212jobs :
13- checks :
14- runs-on : ubuntu-latest
15- steps :
16- - name : Set up Python 3.8
17- uses : actions/setup-python@v1
18- with :
19- python-version : 3.8
20- - name : Checkout code
21- uses : actions/checkout@v2
22- - name : Install dependencies
23- run : |
24- python -m pip install --upgrade pip
25- pip install ".[dev]"
26- - name : Format with black
27- run : |
28- if ! RES=$(black --check $(git diff --name-only --diff-filter=AM master -- "*.py") 2>&1); then
29- RES="${RES//'%'/'%25'}"
30- RES="${RES//$'\n'/'%0A'}"
31- RES="${RES//$'\r'/'%0D'}"
32- echo "::error ::${RES}"
33- exit 1
34- fi
35- echo ${RES}
3613 unit-tests :
37- needs : checks
3814 runs-on : ubuntu-latest
3915 strategy :
4016 matrix :
You can’t perform that action at this time.
0 commit comments