Skip to content

Commit a681d91

Browse files
committed
add a few precommit checks; prefer double quotes; fix ruff checks if able
1 parent b9d2d03 commit a681d91

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

.pre-commit-config.yaml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,30 @@
11
repos:
22
- repo: https://github.com/pre-commit/pre-commit-hooks
3-
rev: "v5.0.0"
3+
rev: "v6.0.0"
44
hooks:
55
- id: check-case-conflict
66
- id: check-merge-conflict
7-
- id: check-toml
8-
- id: check-yaml
97
- id: check-json
108
exclude: ^.devcontainer/.*devcontainer.json
11-
- id: pretty-format-json
12-
exclude: ^.devcontainer/.*devcontainer.json
13-
args: [--autofix, --no-sort-keys]
9+
- id: check-shebang-scripts-are-executable
10+
- id: check-symlinks
11+
- id: check-toml
12+
- id: check-yaml
13+
- id: detect-aws-credentials
14+
- id: detect-private-key
1415
- id: end-of-file-fixer
1516
- id: mixed-line-ending
1617
args: [ --fix=lf ]
18+
- id: pretty-format-json
19+
exclude: ^.devcontainer/.*devcontainer.json
20+
args: [--autofix, --no-sort-keys]
1721
- id: trailing-whitespace
1822

1923
- repo: https://github.com/astral-sh/ruff-pre-commit
2024
rev: "v0.12.7"
2125
hooks:
2226
- id: ruff-check
23-
args: [ --exit-non-zero-on-fix ]
27+
args: [ --fix, --exit-non-zero-on-fix ]
2428
- id: ruff-format
2529

2630
- repo: local

pyproject.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,10 @@ markers = [
109109
src = ["src", "tests"]
110110
line-length = 100
111111

112+
[tool.ruff.format]
113+
quote-style = "double"
114+
docstring-code-format = true
115+
112116
[tool.ruff.lint]
113117
select = [
114118
"F", # https://docs.astral.sh/ruff/rules/#pyflakes-f

0 commit comments

Comments
 (0)