-
Notifications
You must be signed in to change notification settings - Fork 1.6k
45 lines (34 loc) · 1.23 KB
/
standard-checks.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: Standard code checks (MyPy/Pylint/Black/Isort)
on: [push, pull_request]
jobs:
checks:
if: "!contains(github.event.commits[0].message, '[skip ci]')"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: Set up Python 3.11
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: 'poetry'
- name: Install dependencies
run: |
poetry env use "3.11"
poetry install
- name: Check for docstring's
run: |
poetry run pylint --limit-inference-results 0 --enable missing-function-docstring missing-module-docstring missing-class-docstring empty-docstring --disable=all ./spotdl
- name: Run Pylint check
run: |
poetry run pylint --fail-under 10 --limit-inference-results 0 ./spotdl
- name: Run MyPy check
run: |
poetry run mypy --ignore-missing-imports --follow-imports silent --install-types --non-interactive ./spotdl
- name: Run Black check
run: |
poetry run black --check ./spotdl
- name: Run isort check
run: |
poetry run isort --check --diff ./spotdl