GitHub Action to lint Python code (#1025)
* GitHub Action to lint Python code [Ruff](https://beta.ruff.rs/) supports [over 500 lint rules](https://beta.ruff.rs/docs/rules) including bandit, isort, pylint, pyupgrade, and flake8 plus its plugins, and is written in Rust for speed. The `ruff` Action uses minimal steps to __run in ~5 seconds__, rapidly providing intuitive GitHub Annotations to contributors.  * ruff --target-version=py39
This commit is contained in:
7
.github/workflows/tests.yml
vendored
7
.github/workflows/tests.yml
vendored
@@ -3,6 +3,13 @@ name: Tests
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
ruff: # https://beta.ruff.rs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- run: pip install --user ruff
|
||||
- run: ruff --format=github --line-length=7228 --target-version=py39
|
||||
--ignore=E402,E712,E721,E722,E741,F401,F403,F405,F541,F601,F811,F821,F822,F841 .
|
||||
build:
|
||||
runs-on: ${{ matrix.os }}
|
||||
if: "!contains(github.event.head_commit.message, '[skip ci]')"
|
||||
|
||||
Reference in New Issue
Block a user