Skip to content

Commit 53420e4

Browse files
sjmonsonmarkurtz
andauthored
Improve pre-commit usablity for local development (#181)
Enable auto formatting and fixing of benign linting issues in pre-commit. This makes using pre-commit hooks locally a lot less painful. --------- Co-authored-by: Mark Kurtz <mark.j.kurtz@gmail.com>
1 parent 8ced984 commit 53420e4

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

.github/workflows/development.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ jobs:
7979
- name: Install dependencies
8080
run: pip install pre-commit
8181
- name: Run pre-commit checks
82-
run: pre-commit run --all-files
82+
run: SKIP=ruff-format pre-commit run --all-files
8383

8484
ui-precommit-check:
8585
permissions:

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ jobs:
5252
- name: Install dependencies
5353
run: pip install pre-commit
5454
- name: Run pre-commit checks
55-
run: pre-commit run --all-files
55+
run: SKIP=ruff-format pre-commit run --all-files
5656

5757
unit-tests:
5858
runs-on: ubuntu-latest

.pre-commit-config.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ repos:
88
rev: v0.11.7
99
hooks:
1010
- id: ruff
11+
name: run linter
12+
args: [ --fix, --show-fixes ]
13+
- id: ruff-format
14+
name: run formatter
1115
- repo: https://github.com/pre-commit/mirrors-mypy
1216
rev: v1.15.0
1317
hooks:

0 commit comments

Comments
 (0)