From 5fd9c324d556aecac621fd16286fc42780cbd794 Mon Sep 17 00:00:00 2001 From: Christian Clauss Date: Sun, 29 Dec 2024 19:33:27 +0100 Subject: [PATCH 1/2] GitHub Actions: Lint Python code with ruff https://docs.astral.sh/ruff is an extremely fast Python linter and code formatter, written in Rust. With [over 800 linting rules](https://docs.astral.sh/ruff/rules), ruff can be used to replace [Flake8](https://pypi.org/project/flake8/) (plus dozens of plugins), [Black](https://github.com/psf/black), [isort](https://pypi.org/project/isort/), [pydocstyle](https://pypi.org/project/pydocstyle/), [pyupgrade](https://pypi.org/project/pyupgrade/), [autoflake](https://pypi.org/project/autoflake/), and more, all while executing tens or hundreds of times faster than any individual tool. --- .github/workflows/test.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a30bd11..8a91173 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -21,9 +21,10 @@ jobs: node-version: '16' - name: npm install run: npm install - - name: lint + - name: lint JavaScript run: npm run lint - + - name: lint Python + run: pipx ruff check test: name: Test Suite runs-on: ${{ matrix.os }} From 33eabe579f569e9de5c8d65934848d90aa5784e1 Mon Sep 17 00:00:00 2001 From: Christian Clauss Date: Sun, 29 Dec 2024 19:35:18 +0100 Subject: [PATCH 2/2] pipx run ruff check --- .github/workflows/test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8a91173..52faa16 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,7 +24,8 @@ jobs: - name: lint JavaScript run: npm run lint - name: lint Python - run: pipx ruff check + run: pipx run ruff check + test: name: Test Suite runs-on: ${{ matrix.os }}