From 99edf75aa3e092366080514b62014bb823d78703 Mon Sep 17 00:00:00 2001 From: Elias Ericsson-Rydberg Date: Mon, 2 Sep 2024 13:38:29 +0200 Subject: [PATCH] Suggest to move config to pyproject (#7) --- .github/workflows/ci.yml | 6 ++++-- pyproject.toml | 8 ++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 pyproject.toml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f806252..021d236 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,8 +59,10 @@ jobs: id: ruff run: | # It would be nice to push the changes back to the PR branch, but that's difficult to do with forks - ruff check --select I --exit-non-zero-on-fix --output-format=github - ruff format + # Run lint check + ruff check --exit-non-zero-on-fix + # Run format check, non-zero exit code if there are any changes + ruff format --check coverage: runs-on: ubuntu-latest diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..28ae0df --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,8 @@ +[tool.pytest.ini_options] +pythonpath = ["src"] + +[tool.ruff] +output-format = "github" + +[tool.ruff.lint] +select = ["I"]