diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 9949c9c..87810c6 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -1,5 +1,6 @@ name: lint -on: [push] + +on: [push, pull_request] jobs: lint: @@ -8,4 +9,20 @@ jobs: - uses: actions/checkout@v4 - uses: astral-sh/ruff-action@v3 - run: ruff check - - run: ruff format --check + + # typecheck: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 # Make sure this is included + # - name: Set up Python + # uses: actions/setup-python@v4 + # with: + # python-version: '3.x' # Specify your version + # - name: Install dependencies + # run: | + # python -m pip install --upgrade pip + # pip install -r requirements.txt # Or your dependency file + # - name: Run Pyright + # uses: jakebailey/pyright-action@v2 + # with: + # project: ./pyrightconfig.json # If you have a config file diff --git a/ruff.toml b/ruff.toml index 0272688..9743725 100644 --- a/ruff.toml +++ b/ruff.toml @@ -37,8 +37,14 @@ target-version = "py39" [lint] # Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default. -# Note the formatter takes care of trailing commas -select = ["E4", "E7", "E9", "F", "W292"] +select = ["E4", "E7", "E9", "F", + # missing-newline-at-end-of-file + "W292", + # trailing commas + "COM812", "COM819", + # use double quotes + "Q000" +] ignore = [] # Allow fix for all enabled rules (when `--fix`) is provided. @@ -47,16 +53,3 @@ unfixable = [] # Allow unused variables when underscore-prefixed. dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$" - -[format] -# Like Black, use double quotes for strings. -quote-style = "double" - -# Like Black, indent with spaces, rather than tabs. -indent-style = "space" - -# Like Black, respect magic trailing commas. -skip-magic-trailing-comma = false - -# Like Black, automatically detect the appropriate line ending. -line-ending = "auto"