diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9ed22ef..856f56c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -86,7 +86,8 @@ repos: rev: 23.10.0 hooks: - id: black - args: ["--line-length", "79", "--target-version", "py310"] + #Refer to pyproject.toml + #args: ["--line-length", "79", "--target-version", "py310"] #- id: black-jupyter - repo: https://github.com/scop/pre-commit-shfmt rev: v3.7.0-1 diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..2a2b459 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,22 @@ +# When changing this file, read also .pre-commit-config.yaml + +[tool.black] +line-length = 79 +target-version = ['py310'] + +[tool.mypy] +#python-executable = 'pypy3' +python-version = 3.10 + +# https://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.html + +# No need to have it uncommented since 79 is the standard. +#[tool.pylint.format] +#max-line-length = 79 + +# Not actually used here, see .pre-commit-config.yaml for reorder-python-imports +# that does the same thing. +#[tool.isort] +#profile = "black" + +# copy-pasted comments end.