-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyproject.toml
137 lines (117 loc) · 3.78 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
[project]
name = "chatgpt-pre-commit-hooks"
description = "Pre-commit hooks collection that utilizes ChatGPT and OpenAI platform to validate modifications made to the codebase."
readme = "README.md"
dynamic = ["version"]
authors = [
{ name = "Dariusz Porowski", email = "[email protected]" },
]
keywords = [
"chatgpt",
"openai",
"pre-commit",
"pre-commit-hooks",
"pre-commit-hook",
]
license = { text = "MIT" }
requires-python = ">=3.8"
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Version Control",
"Topic :: Software Development :: Version Control :: Git",
]
dependencies = ["openai~=0.27.4", "tiktoken>=0.3.3,<0.5.0"]
[project.urls]
"Homepage" = "https://github.com/DariuszPorowski/chatgpt-pre-commit-hooks/blob/main/README.md"
"Bug Tracker" = "https://github.com/DariuszPorowski/chatgpt-pre-commit-hooks/issues"
[project.optional-dependencies]
dev = ["ruff", "mypy", "pre-commit", "pyyaml", "types-PyYAML"]
build = ["build", "wheel", "twine"]
[project.scripts]
chatgpt-commit-message = "chatgpt_pre_commit_hooks.hook_chatgpt_commit_message:main"
chatgpt-pre-commit-hooks = "chatgpt_pre_commit_hooks.main:main"
[build-system]
requires = ["setuptools", "build", "setuptools_scm[toml]"]
build-backend = "setuptools.build_meta"
[tool.setuptools]
zip-safe = false
# packages = ["chatgpt_pre_commit_hooks"]
[tool.setuptools.packages.find]
include = ["chatgpt_pre_commit_hooks"]
exclude = ["tests*", ".*"]
[tool.setuptools_scm]
# It would be nice to include the commit hash in the version, but that can't be done in a PEP 440-compatible way.
version_scheme = "no-guess-dev"
# Test PyPI does not support local versions.
local_scheme = "no-local-version"
fallback_version = "0.0.0"
[tool.ruff]
# https://beta.ruff.rs/docs/settings/
select = ["ALL"]
line-length = 180
target-version = "py39"
format = "grouped"
show-fixes = true
force-exclude = true
ignore = ["ANN101", "G004"] #, "TRY003", "EM102", "BLE001", "EXE002"]
exclude = [".github/scripts/*"]
[tool.ruff.pycodestyle]
max-doc-length = 180
[tool.ruff.pydocstyle]
# Use Google-style docstrings
convention = "google"
[tool.ruff.per-file-ignores]
"tests/*" = ["S101"]
[tool.pyright]
# vscode support
# https://microsoft.github.io/pyright/#/configuration
venvPath = ".venv"
[tool.autopep8]
max_line_length = 180
in-place = true
recursive = true
aggressive = 3
exclude_globs = [".venv"]
[tool.isort]
# https://pycqa.github.io/isort/docs/configuration/options.html
py_version = 39
profile = "black"
[tool.black]
# https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#configuration-format
target-version = ["py39"]
line-length = 180
[tool.pylint]
# https://pylint.readthedocs.io/en/latest/user_guide/configuration/all-options.html
py-version = "3.9"
ignore = [".venv"]
max-line-length = 180
recursive = true
disable = ["W1203", "W0212", "R0903", "W0612"]
[tool.pydocstyle]
# https://www.pydocstyle.org/en/stable/usage.html#available-options
convention = "google"
[tool.mypy]
# https://mypy.readthedocs.io/en/stable/config_file.html
python_version = "3.9"
exclude = [".venv"]
disallow_any_unimported = true
show_column_numbers = true
show_error_context = true
pretty = true
explicit_package_bases = true
ignore_missing_imports = true
follow_imports = "silent"
show_error_codes = true
[tool.bandit]
# https://bandit.readthedocs.io/en/latest/config.html#bandit-settings
exclude_dirs = [".venv"]
[tool.bandit.assert_used]
skips = ["*/test_*.py"]