Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,8 @@ repos:
- pytest
- tomli
- types-chardet
- repo: https://github.com/ComPWA/mirrors-taplo
rev: "v0.9.3"
hooks:
- id: taplo-format
entry: env RUST_LOG=warn taplo fmt --option indent_string=' '
41 changes: 17 additions & 24 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,8 @@ name = "codespell"
description = "Fix common misspellings in text files"
readme = { file = "README.rst", content-type = "text/x-rst" }
requires-python = ">=3.8"
license = {text = "GPL-2.0-only"}
authors = [
{name = "Lucas De Marchi", email = "[email protected]"},
]
license = { text = "GPL-2.0-only" }
authors = [{ name = "Lucas De Marchi", email = "[email protected]" }]
classifiers = [
"Intended Audience :: Developers",
"License :: OSI Approved",
Expand Down Expand Up @@ -41,21 +39,11 @@ dev = [
"Pygments",
"ruff",
"tomli",
"twine"
]
hard-encoding-detection = [
"chardet"
]
toml = [
"tomli; python_version < '3.11'"
]
types = [
"chardet>=5.1.0",
"mypy",
"pytest",
"pytest-cov",
"pytest-dependency",
"twine",
]
hard-encoding-detection = ["chardet"]
toml = ["tomli; python_version < '3.11'"]
types = ["chardet>=5.1.0", "mypy", "pytest", "pytest-cov", "pytest-dependency"]

[project.scripts]
codespell = "codespell_lib:_script_main"
Expand All @@ -72,10 +60,7 @@ requires = ["setuptools>=64", "setuptools_scm[toml]>=6.2, != 8.0.0"]
write_to = "codespell_lib/_version.py"

[tool.setuptools.packages.find]
exclude = [
"dist",
"snap",
]
exclude = ["dist", "snap"]

[tool.setuptools.package-data]
codespell_lib = [
Expand All @@ -102,7 +87,15 @@ minversion = "6"
testpaths = ["codespell_lib/tests"]
log_cli_level = "INFO"
xfail_strict = true
addopts = ["--cov=codespell_lib", "-rs", "--strict-config", "--strict-markers", "--cov-report=", "--tb=short", "--junit-xml=junit-results.xml"]
addopts = [
"--cov=codespell_lib",
"-rs",
"--strict-config",
"--strict-markers",
"--cov-report=",
"--tb=short",
"--junit-xml=junit-results.xml",
]
filterwarnings = ["error"]

[tool.ruff]
Expand Down Expand Up @@ -167,7 +160,7 @@ max-complexity = 45
"codespell_lib/tests/test_basic.py" = ["ANN401", "N802"]

[tool.ruff.lint.pylint]
allow-magic-value-types = ["bytes", "int", "str",]
allow-magic-value-types = ["bytes", "int", "str"]
max-args = 13
max-branches = 48
max-returns = 12
Expand Down
Loading