Skip to content

Commit

Permalink
run linters manually in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
samschott committed Nov 22, 2022
1 parent 36c99c8 commit 3012dfd
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 38 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,18 @@ on:
workflow_dispatch:

jobs:
pre-commit:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/[email protected]
- run: python -m pip install -U .[dev]
- uses: pre-commit/[email protected]
- run: python -m pip install -U .[lint]
- name: black
run: |
black --check src tests
- name: flake8
run: |
flake8 src tests
- name: mypy
run: |
mypy src
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -U .[dev]
python -m pip install -U .[test]
- name: Test with pytest
run: |
Expand Down Expand Up @@ -91,7 +91,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -U .[dev]
python -m pip install -U .[test]
- name: Get short-lived Dropbox token
# We generate a short-lived auth token which is passed to the test runner as
Expand Down Expand Up @@ -164,7 +164,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -U .[dev]
python -m pip install -U .[test]
- name: Get short-lived Dropbox token
# We generate a short-lived auth token which is passed to the test runner as
Expand Down
24 changes: 0 additions & 24 deletions .pre-commit-config.yaml

This file was deleted.

27 changes: 19 additions & 8 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -67,19 +67,23 @@ pyinstaller40 =
gui =
maestral-qt>=1.6.3;sys_platform=='linux'
maestral-cocoa>=1.6.3;sys_platform=='darwin'
syslog = systemd-python
syslog =
systemd-python
dev =
black
pre-commit
bump2version
lint =
black
flake8
mypy
pre-commit
pyupgrade
types-pkg_resources
types-requests
test =
pytest
pytest-benchmark
pytest-cov
pytest-rerunfailures
types-pkg_resources
types-requests
docs =
sphinx
sphinxext-opengraph
Expand All @@ -92,7 +96,14 @@ ignore = E203,E501,W503,H306
statistics = True

[mypy]
files = src, tests
python_version = 3.7
warn_redundant_casts = True
python_version = 3.8
ignore_missing_imports = True
disallow_any_generics = True
disallow_untyped_defs = True
disallow_incomplete_defs = True
check_untyped_defs = True
disallow_untyped_decorators = True
warn_redundant_casts = True
no_implicit_reexport = True
strict_equality = True
strict_concatenate = True

0 comments on commit 3012dfd

Please sign in to comment.