Skip to content

Commit a87c108

Browse files
yarikopticLee-W
authored andcommitted
style: move codespell configuration to pyproject.toml
So people could just run "codespell" without pre-commit and have centralized configuration for tools (the others are already in pyproject.toml) Signed-off-by: Yaroslav Halchenko <debian@onerussian.com>
1 parent 86d6aea commit a87c108

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

.pre-commit-config.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,10 @@ repos:
4141
hooks:
4242
- id: codespell
4343
name: Run codespell to check for common misspellings in files
44+
# config section is within pyproject.toml
4445
language: python
4546
types: [ text ]
46-
args: [ "--write-changes", "--ignore-words-list", "asend" ]
47-
exclude: "poetry.lock"
47+
args: [ "--write-changes" ]
4848

4949
- repo: https://github.com/commitizen-tools/commitizen
5050
rev: v3.27.0 # automatically updated by Commitizen

pyproject.toml

+6
Original file line numberDiff line numberDiff line change
@@ -181,3 +181,9 @@ warn_unused_configs = true
181181
[[tool.mypy.overrides]]
182182
module = "py.*" # Legacy pytest dependencies
183183
ignore_missing_imports = true
184+
185+
[tool.codespell]
186+
# Ref: https://github.com/codespell-project/codespell#using-a-config-file
187+
skip = '.git*,*.svg,*.lock'
188+
check-hidden = true
189+
ignore-words-list = 'asend'

0 commit comments

Comments
 (0)