-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
182 lines (153 loc) · 5.63 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
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
[build-system]
requires = ["poetry>=0.12"]
build-backend = "poetry.masonry.api"
# -- POETRY CONFIG ---------------------------------------------------------------------
[tool.poetry]
name = "commit-msg-jira-hook"
version = "1.0.0"
description = "commit-msg hook for jira issue verification with pre-commit."
authors = ["Cielquan <cielquan@protonmail.com>"]
license = "GPL-3.0-or-later"
keywords = ["pre-commit", "hook", "git", "commit-msg"]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Topic :: Software Development :: Version Control :: Git",
]
repository = "https://github.com/Cielquan/commit-msg-jira-hook"
readme = "README.rst"
packages = [
{ include = "commit_msg_jira_hook", from = "src" },
]
[tool.poetry.dependencies]
python = "^3.6.1"
importlib-metadata = {version = "^1.6", python = "<3.8"}
jira = "^2.0.0"
click = "^7.1.2"
gitpython = "^3.1.7"
#: Testing
pytest = {version = ">=6", optional = true}
pytest-xdist = {version = ">=1.34", optional = true}
pytest-cov = {version = ">=2.10", optional = true}
coverage = {extras = ["toml"], version = ">=5.2.1", optional = true}
pytest-sugar = {version = ">=0.9.4", optional = true}
pytest-randomly = {version = ">=3.4", optional = true}
#: Code check
pre-commit = {version = ">=2.4", optional = true}
mypy = {version = ">=0.782", optional = true}
pylint = {version = ">=2.5.3", optional = true}
[tool.poetry.dev-dependencies]
devtools = {version = ">=0.6", extras = ["pygments"]}
towncrier = {version = "19.9.0rc1"}
ipython = ">=7.15.0"
[tool.poetry.extras]
testing = [
"pytest", "pytest-xdist",
"pytest-cov", "coverage",
"pytest-sugar",
"pytest-randomly",
"pytest-mock", "mock",
]
pre-commit = ["pre-commit", "mypy", "pylint"]
linter = [
"mypy", "pylint", "flake8", "bandit",
"pydocstyle", "rstcheck"
] #: for VSCode
[tool.poetry.scripts]
jira_commit_msg = "commit_msg_jira_hook.check_jira_tag:main"
jira_prepare_commit_msg = "commit_msg_jira_hook.add_jira_tag:main"
# -- TOWNCRIER CONFIG ------------------------------------------------------------------
[tool.towncrier]
package = "commit_msg_jira_hook"
package_dir = "src"
filename = "CHANGELOG.rst"
directory = "docs/.changes"
template = "docs/.changes/template.jinja2"
title_format = "v{version} ({project_date})"
issue_format = "`#{issue} <https://github.com/cielquan/commit-msg-jira-hook/issues/{issue}>`_"
underlines = ["-", "~"]
wrap = false # Wrap text to 79 characters
all_bullets = true # make all fragments bullet points
[[tool.towncrier.type]]
directory = "bugfix"
name = "Bugfixes"
showcontent = true
[[tool.towncrier.type]]
directory = "feat"
name = "New Features"
showcontent = true
[[tool.towncrier.type]]
directory = "breaking"
name = "Backwards incompatible changes"
showcontent = true
[[tool.towncrier.type]]
directory = "depr"
name = "Deprecations (removal in next major release)"
showcontent = true
[[tool.towncrier.type]]
directory = "docs"
name = "Documentation"
showcontent = true
[[tool.towncrier.type]]
directory = "misc"
name = "Miscellaneous"
showcontent = true
#: -- BLACK CONFIG ---------------------------------------------------------------------
[tool.black]
line-length = 88
exclude = "venv/"
include = '\.pyi?$'
#: -- ISORT CONFIG ---------------------------------------------------------------------
[tool.isort]
profile = "black"
lines_after_imports = 2
lines_between_types = 1
skip_gitignore = true
#: -- PYLINT CONFIG --------------------------------------------------------------------
[tool.pylint.master]
additional-builtins = "tags"
[tool.pylint.messages_control]
disable = "C0330, C0326" #: deactivated for black
[tool.pylint.format]
max-line-length = "88"
#: -- COVERAGE CONFIG ------------------------------------------------------------------
[tool.coverage]
[tool.coverage.run]
branch = true
parallel = true
context = "static-context"
omit = [
"tests/*",
"docs/*",
]
[tool.coverage.paths]
combine = [
"src/commit_msg_jira_hook",
"*/.tox/*/lib/python*/site-packages/commit_msg_jira_hook",
"*/.tox/pypy*/site-packages/commit_msg_jira_hook",
"*/.tox\\*\\Lib\\site-packages\\commit_msg_jira_hook",
"*/src/commit_msg_jira_hook",
"*\\src\\commit_msg_jira_hook",
]
[tool.coverage.report]
#fail_under = 100
show_missing = true
exclude_lines = [
"# pragma: no cover",
"if __name__ == ['\"]__main__['\"]:",
"def __str__",
"def __repr__",
"if self.debug:",
"if settings.DEBUG",
"if 0:",
"if False:",
"if TYPE_CHECKING:",
"if MYPY:",
]
[tool.coverage.html]
show_contexts = true
#: -- PYTEST CONFIG --------------------------------------------------------------------
[tool.pytest.ini_options]
addopts = "-ra --showlocals"
mock_use_standalone_module = true
junit_family = "xunit2"