diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3017978009..1d7b798ff5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -41,10 +41,12 @@ repos: hooks: - id: codespell name: Run codespell to check for common misspellings in files + # config section is within pyproject.toml language: python types: [ text ] - args: [ "--write-changes", "--ignore-words-list", "asend" ] - exclude: "poetry.lock" + args: [ "--write-changes" ] + additional_dependencies: + - tomli - repo: https://github.com/commitizen-tools/commitizen rev: v3.26.2 # automatically updated by Commitizen diff --git a/pyproject.toml b/pyproject.toml index 22eece6bce..d851021910 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -174,3 +174,9 @@ warn_unused_configs = true [[tool.mypy.overrides]] module = "py.*" # Legacy pytest dependencies ignore_missing_imports = true + +[tool.codespell] +# Ref: https://github.com/codespell-project/codespell#using-a-config-file +skip = '.git*,*.svg,*.lock' +check-hidden = true +ignore-words-list = 'asend'