Skip to content

Commit ab7bc1a

Browse files
committed
Add pre-commit hooks and pydocstyle convention
Add several pre-commit hooks (check-added-large-files, check-yaml, check-toml, name-tests-test, check-merge-conflict) alongside existing EOF and trailing-whitespace fixes to improve repo hygiene and catch common issues early. Also configure ruff's pydocstyle convention to "google" in pyproject.toml to enforce Google-style docstrings.
1 parent 1dae79e commit ab7bc1a

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

.pre-commit-config.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@ repos:
22
- repo: https://github.com/pre-commit/pre-commit-hooks
33
rev: v6.0.0
44
hooks:
5-
- id: check-docstring-first
5+
- id: check-added-large-files
6+
- id: check-yaml
7+
- id: check-toml
68
- id: end-of-file-fixer
9+
- id: name-tests-test
710
- id: trailing-whitespace
811
- repo: https://github.com/astral-sh/ruff-pre-commit
912
rev: v0.15.4

pyproject.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ fix = true
8686
[tool.ruff.lint]
8787
select = [ "E", "F", "B", "I", "UP" ]
8888
ignore = [ "E741" ]
89+
[tool.ruff.lint.pydocstyle]
90+
convention = "google"
8991

9092
[tool.pyproject-fmt]
9193
max_supported_python = "3.12"

0 commit comments

Comments
 (0)