diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 0000000..a3bd0ca --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,27 @@ +name: lint + +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + lint: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Setup Python + uses: actions/setup-python@v2 + with: + python-version: 3.9.0-beta.4 - 3.9.0 + + - name: Install tox + run: python -m pip install tox + + - name: Main check + run: python -m tox -e lint diff --git a/tox.ini b/tox.ini index 400cc4f..317d3b6 100644 --- a/tox.ini +++ b/tox.ini @@ -7,14 +7,16 @@ isolated_build = True deps = Cython scipy - flake8 pytest-cov -commands = - flake8 - pytest +commands = pytest setenv = CYTHON_TRACE = 1 passenv = TRAVIS +[testenv:lint] +skip_install = true +deps = flake8 +commands = flake8 + [flake8] filename = *.pxd, *.pyx, *.py hang-closing = True