From 3e939cf60ced4789a5103fb6c40597c215a90c7e Mon Sep 17 00:00:00 2001 From: Jannis R Date: Thu, 31 Aug 2023 14:38:10 +0200 Subject: [PATCH] =?UTF-8?q?on=20pushes=20&=20PRs,=20lint=20using=20GitHub?= =?UTF-8?q?=20Actions=20=F0=9F=92=9A=20[todo]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/lint.yml | 41 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/lint.yml diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 0000000..b7b9170 --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,41 @@ +name: lint + +on: + push: + branches: + - '*' + pull_request: + branches: + - '*' + +jobs: + lint: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: + - '3' + + steps: + - name: checkout + uses: actions/checkout@v3 + - name: setup Python v${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + cache: 'pip' + + - name: pip install + run: pip install -r requirements.txt -r requirements-dev.txt + + - name: lint using ruff + # uses: chartboost/ruff-action@v1 + run: ruff check --format=github . + + - name: format using black + run: | + black -S --check --diff . + + - name: type-check using mypy + run: | + mypy .