commitizen 3.29.0__tar.gz → 3.29.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {commitizen-3.29.0 → commitizen-3.29.1}/PKG-INFO +11 -3
- commitizen-3.29.1/commitizen/__version__.py +1 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog.py +13 -8
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog_formats/asciidoc.py +13 -1
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog_formats/base.py +9 -1
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog_formats/markdown.py +15 -1
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog_formats/restructuredtext.py +23 -5
- commitizen-3.29.1/commitizen/changelog_formats/textile.py +42 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/changelog.py +4 -5
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/defaults.py +19 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/scm_provider.py +2 -8
- {commitizen-3.29.0 → commitizen-3.29.1}/docs/README.md +10 -2
- {commitizen-3.29.0 → commitizen-3.29.1}/pyproject.toml +3 -3
- commitizen-3.29.0/commitizen/__version__.py +0 -1
- commitizen-3.29.0/commitizen/changelog_formats/textile.py +0 -25
- {commitizen-3.29.0 → commitizen-3.29.1}/LICENSE +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/__main__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/bump.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/changelog_formats/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cli.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cmd.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/bump.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/check.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/commit.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/example.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/info.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/init.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/list_cz.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/schema.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/commands/version.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/config/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/config/base_config.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/config/json_config.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/config/toml_config.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/config/yaml_config.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/base.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/conventional_commits/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/conventional_commits/conventional_commits.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/conventional_commits/conventional_commits_info.txt +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/customize/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/customize/customize.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/customize/customize_info.txt +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/exceptions.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/jira/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/jira/jira.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/jira/jira_info.txt +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/utils.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/exceptions.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/factory.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/git.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/hooks.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/out.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/__init__.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/base_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/cargo_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/commitizen_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/composer_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/npm_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/pep621_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/providers/poetry_provider.py +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/py.typed +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/templates/CHANGELOG.adoc.j2 +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/templates/CHANGELOG.md.j2 +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/templates/CHANGELOG.rst.j2 +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/templates/CHANGELOG.textile.j2 +0 -0
- {commitizen-3.29.0 → commitizen-3.29.1}/commitizen/version_schemes.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: commitizen
|
|
3
|
-
Version: 3.29.
|
|
3
|
+
Version: 3.29.1
|
|
4
4
|
Summary: Python commitizen client tool
|
|
5
5
|
Home-page: https://github.com/commitizen-tools/commitizen
|
|
6
6
|
License: MIT
|
|
@@ -84,10 +84,18 @@ descriptive commits.
|
|
|
84
84
|
|
|
85
85
|
## Installation
|
|
86
86
|
|
|
87
|
-
|
|
87
|
+
Install commitizen in your system using `pipx` (Recommended, <https://pypa.github.io/pipx/installation/>):
|
|
88
88
|
|
|
89
89
|
```bash
|
|
90
|
-
|
|
90
|
+
pipx ensurepath
|
|
91
|
+
pipx install commitizen
|
|
92
|
+
pipx upgrade commitizen
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
Install commitizen using `pip` with `--user` flag:
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
pip install --user -U commitizen
|
|
91
99
|
```
|
|
92
100
|
|
|
93
101
|
### Python project
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "3.29.1"
|
|
@@ -44,6 +44,7 @@ from jinja2 import (
|
|
|
44
44
|
from commitizen import out
|
|
45
45
|
from commitizen.bump import normalize_tag
|
|
46
46
|
from commitizen.cz.base import ChangelogReleaseHook
|
|
47
|
+
from commitizen.defaults import get_tag_regexes
|
|
47
48
|
from commitizen.exceptions import InvalidConfigurationError, NoCommitsFoundError
|
|
48
49
|
from commitizen.git import GitCommit, GitTag
|
|
49
50
|
from commitizen.version_schemes import (
|
|
@@ -93,16 +94,21 @@ def tag_included_in_changelog(
|
|
|
93
94
|
return True
|
|
94
95
|
|
|
95
96
|
|
|
96
|
-
def get_version_tags(
|
|
97
|
+
def get_version_tags(
|
|
98
|
+
scheme: type[BaseVersion], tags: list[GitTag], tag_format: str
|
|
99
|
+
) -> list[GitTag]:
|
|
97
100
|
valid_tags: list[GitTag] = []
|
|
101
|
+
TAG_FORMAT_REGEXS = get_tag_regexes(scheme.parser.pattern)
|
|
102
|
+
tag_format_regex = tag_format
|
|
103
|
+
for pattern, regex in TAG_FORMAT_REGEXS.items():
|
|
104
|
+
tag_format_regex = tag_format_regex.replace(pattern, regex)
|
|
98
105
|
for tag in tags:
|
|
99
|
-
|
|
100
|
-
scheme(tag.name)
|
|
101
|
-
except InvalidVersion:
|
|
102
|
-
out.warn(f"InvalidVersion {tag}")
|
|
103
|
-
else:
|
|
106
|
+
if re.match(tag_format_regex, tag.name):
|
|
104
107
|
valid_tags.append(tag)
|
|
105
|
-
|
|
108
|
+
else:
|
|
109
|
+
out.warn(
|
|
110
|
+
f"InvalidVersion {tag.name} doesn't match configured tag format {tag_format}"
|
|
111
|
+
)
|
|
106
112
|
return valid_tags
|
|
107
113
|
|
|
108
114
|
|
|
@@ -351,7 +357,6 @@ def get_oldest_and_newest_rev(
|
|
|
351
357
|
oldest, newest = version.split("..")
|
|
352
358
|
except ValueError:
|
|
353
359
|
newest = version
|
|
354
|
-
|
|
355
360
|
newest_tag = normalize_tag(newest, tag_format=tag_format, scheme=scheme)
|
|
356
361
|
|
|
357
362
|
oldest_tag = None
|
|
@@ -18,7 +18,19 @@ class AsciiDoc(BaseFormat):
|
|
|
18
18
|
matches = list(re.finditer(self.version_parser, m.group("title")))
|
|
19
19
|
if not matches:
|
|
20
20
|
return None
|
|
21
|
-
|
|
21
|
+
if "version" in matches[-1].groupdict():
|
|
22
|
+
return matches[-1].group("version")
|
|
23
|
+
partial_matches = matches[-1].groupdict()
|
|
24
|
+
try:
|
|
25
|
+
partial_version = f"{partial_matches['major']}.{partial_matches['minor']}.{partial_matches['patch']}"
|
|
26
|
+
except KeyError:
|
|
27
|
+
return None
|
|
28
|
+
|
|
29
|
+
if partial_matches.get("prerelease"):
|
|
30
|
+
partial_version = f"{partial_version}-{partial_matches['prerelease']}"
|
|
31
|
+
if partial_matches.get("devrelease"):
|
|
32
|
+
partial_version = f"{partial_version}{partial_matches['devrelease']}"
|
|
33
|
+
return partial_version
|
|
22
34
|
|
|
23
35
|
def parse_title_level(self, line: str) -> int | None:
|
|
24
36
|
m = self.RE_TITLE.match(line)
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
2
|
|
|
3
3
|
import os
|
|
4
|
+
import re
|
|
4
5
|
from abc import ABCMeta
|
|
5
6
|
from re import Pattern
|
|
6
7
|
from typing import IO, Any, ClassVar
|
|
7
8
|
|
|
8
9
|
from commitizen.changelog import Metadata
|
|
9
10
|
from commitizen.config.base_config import BaseConfig
|
|
11
|
+
from commitizen.defaults import get_tag_regexes
|
|
10
12
|
from commitizen.version_schemes import get_version_scheme
|
|
11
13
|
|
|
12
14
|
from . import ChangelogFormat
|
|
@@ -25,10 +27,16 @@ class BaseFormat(ChangelogFormat, metaclass=ABCMeta):
|
|
|
25
27
|
# See: https://bugs.python.org/issue44807
|
|
26
28
|
self.config = config
|
|
27
29
|
self.encoding = self.config.settings["encoding"]
|
|
30
|
+
self.tag_format = self.config.settings["tag_format"]
|
|
28
31
|
|
|
29
32
|
@property
|
|
30
33
|
def version_parser(self) -> Pattern:
|
|
31
|
-
|
|
34
|
+
tag_regex: str = self.tag_format
|
|
35
|
+
version_regex = get_version_scheme(self.config).parser.pattern
|
|
36
|
+
TAG_FORMAT_REGEXS = get_tag_regexes(version_regex)
|
|
37
|
+
for pattern, regex in TAG_FORMAT_REGEXS.items():
|
|
38
|
+
tag_regex = tag_regex.replace(pattern, regex)
|
|
39
|
+
return re.compile(tag_regex)
|
|
32
40
|
|
|
33
41
|
def get_metadata(self, filepath: str) -> Metadata:
|
|
34
42
|
if not os.path.isfile(filepath):
|
|
@@ -19,7 +19,21 @@ class Markdown(BaseFormat):
|
|
|
19
19
|
m = re.search(self.version_parser, m.group("title"))
|
|
20
20
|
if not m:
|
|
21
21
|
return None
|
|
22
|
-
|
|
22
|
+
if "version" in m.groupdict():
|
|
23
|
+
return m.group("version")
|
|
24
|
+
matches = m.groupdict()
|
|
25
|
+
try:
|
|
26
|
+
partial_version = (
|
|
27
|
+
f"{matches['major']}.{matches['minor']}.{matches['patch']}"
|
|
28
|
+
)
|
|
29
|
+
except KeyError:
|
|
30
|
+
return None
|
|
31
|
+
|
|
32
|
+
if matches.get("prerelease"):
|
|
33
|
+
partial_version = f"{partial_version}-{matches['prerelease']}"
|
|
34
|
+
if matches.get("devrelease"):
|
|
35
|
+
partial_version = f"{partial_version}{matches['devrelease']}"
|
|
36
|
+
return partial_version
|
|
23
37
|
|
|
24
38
|
def parse_title_level(self, line: str) -> int | None:
|
|
25
39
|
m = self.RE_TITLE.match(line)
|
|
@@ -46,7 +46,6 @@ class RestructuredText(BaseFormat):
|
|
|
46
46
|
third = third.strip().lower()
|
|
47
47
|
title: str | None = None
|
|
48
48
|
kind: TitleKind | None = None
|
|
49
|
-
|
|
50
49
|
if self.is_overlined_title(first, second, third):
|
|
51
50
|
title = second
|
|
52
51
|
kind = (first[0], third[0])
|
|
@@ -67,10 +66,29 @@ class RestructuredText(BaseFormat):
|
|
|
67
66
|
# Try to find the latest release done
|
|
68
67
|
m = re.search(self.version_parser, title)
|
|
69
68
|
if m:
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
69
|
+
matches = m.groupdict()
|
|
70
|
+
if "version" in matches:
|
|
71
|
+
version = m.group("version")
|
|
72
|
+
meta.latest_version = version
|
|
73
|
+
meta.latest_version_position = index
|
|
74
|
+
break # there's no need for more info
|
|
75
|
+
try:
|
|
76
|
+
partial_version = (
|
|
77
|
+
f"{matches['major']}.{matches['minor']}.{matches['patch']}"
|
|
78
|
+
)
|
|
79
|
+
if matches.get("prerelease"):
|
|
80
|
+
partial_version = (
|
|
81
|
+
f"{partial_version}-{matches['prerelease']}"
|
|
82
|
+
)
|
|
83
|
+
if matches.get("devrelease"):
|
|
84
|
+
partial_version = (
|
|
85
|
+
f"{partial_version}{matches['devrelease']}"
|
|
86
|
+
)
|
|
87
|
+
meta.latest_version = partial_version
|
|
88
|
+
meta.latest_version_position = index
|
|
89
|
+
break
|
|
90
|
+
except KeyError:
|
|
91
|
+
pass
|
|
74
92
|
if meta.unreleased_start is not None and meta.unreleased_end is None:
|
|
75
93
|
meta.unreleased_end = (
|
|
76
94
|
meta.latest_version_position if meta.latest_version else index + 1
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import re
|
|
4
|
+
|
|
5
|
+
from .base import BaseFormat
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Textile(BaseFormat):
|
|
9
|
+
extension = "textile"
|
|
10
|
+
|
|
11
|
+
RE_TITLE = re.compile(r"^h(?P<level>\d)\. (?P<title>.*)$")
|
|
12
|
+
|
|
13
|
+
def parse_version_from_title(self, line: str) -> str | None:
|
|
14
|
+
if not self.RE_TITLE.match(line):
|
|
15
|
+
return None
|
|
16
|
+
m = re.search(self.version_parser, line)
|
|
17
|
+
if not m:
|
|
18
|
+
return None
|
|
19
|
+
if "version" in m.groupdict():
|
|
20
|
+
return m.group("version")
|
|
21
|
+
matches = m.groupdict()
|
|
22
|
+
if not all(
|
|
23
|
+
[
|
|
24
|
+
version_segment in matches
|
|
25
|
+
for version_segment in ("major", "minor", "patch")
|
|
26
|
+
]
|
|
27
|
+
):
|
|
28
|
+
return None
|
|
29
|
+
|
|
30
|
+
partial_version = f"{matches['major']}.{matches['minor']}.{matches['patch']}"
|
|
31
|
+
|
|
32
|
+
if matches.get("prerelease"):
|
|
33
|
+
partial_version = f"{partial_version}-{matches['prerelease']}"
|
|
34
|
+
if matches.get("devrelease"):
|
|
35
|
+
partial_version = f"{partial_version}{matches['devrelease']}"
|
|
36
|
+
return partial_version
|
|
37
|
+
|
|
38
|
+
def parse_title_level(self, line: str) -> int | None:
|
|
39
|
+
m = self.RE_TITLE.match(line)
|
|
40
|
+
if not m:
|
|
41
|
+
return None
|
|
42
|
+
return int(m.group("level"))
|
|
@@ -168,8 +168,10 @@ class Changelog:
|
|
|
168
168
|
# Don't continue if no `file_name` specified.
|
|
169
169
|
assert self.file_name
|
|
170
170
|
|
|
171
|
-
tags =
|
|
172
|
-
|
|
171
|
+
tags = (
|
|
172
|
+
changelog.get_version_tags(self.scheme, git.get_tags(), self.tag_format)
|
|
173
|
+
or []
|
|
174
|
+
)
|
|
173
175
|
end_rev = ""
|
|
174
176
|
if self.incremental:
|
|
175
177
|
changelog_meta = self.changelog_format.get_metadata(self.file_name)
|
|
@@ -182,7 +184,6 @@ class Changelog:
|
|
|
182
184
|
start_rev = self._find_incremental_rev(
|
|
183
185
|
strip_local_version(latest_tag_version), tags
|
|
184
186
|
)
|
|
185
|
-
|
|
186
187
|
if self.rev_range:
|
|
187
188
|
start_rev, end_rev = changelog.get_oldest_and_newest_rev(
|
|
188
189
|
tags,
|
|
@@ -190,13 +191,11 @@ class Changelog:
|
|
|
190
191
|
tag_format=self.tag_format,
|
|
191
192
|
scheme=self.scheme,
|
|
192
193
|
)
|
|
193
|
-
|
|
194
194
|
commits = git.get_commits(start=start_rev, end=end_rev, args="--topo-order")
|
|
195
195
|
if not commits and (
|
|
196
196
|
self.current_version is None or not self.current_version.is_prerelease
|
|
197
197
|
):
|
|
198
198
|
raise NoCommitsFoundError("No commits found")
|
|
199
|
-
|
|
200
199
|
tree = changelog.generate_tree_from_commits(
|
|
201
200
|
commits,
|
|
202
201
|
tags,
|
|
@@ -132,3 +132,22 @@ bump_map_major_version_zero = OrderedDict(
|
|
|
132
132
|
)
|
|
133
133
|
change_type_order = ["BREAKING CHANGE", "Feat", "Fix", "Refactor", "Perf"]
|
|
134
134
|
bump_message = "bump: version $current_version → $new_version"
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
def get_tag_regexes(
|
|
138
|
+
version_regex: str,
|
|
139
|
+
) -> dict[str, str]:
|
|
140
|
+
return {
|
|
141
|
+
"$version": version_regex,
|
|
142
|
+
"$major": r"(?P<major>\d+)",
|
|
143
|
+
"$minor": r"(?P<minor>\d+)",
|
|
144
|
+
"$patch": r"(?P<patch>\d+)",
|
|
145
|
+
"$prerelease": r"(?P<prerelease>\w+\d+)?",
|
|
146
|
+
"$devrelease": r"(?P<devrelease>\.dev\d+)?",
|
|
147
|
+
"${version}": version_regex,
|
|
148
|
+
"${major}": r"(?P<major>\d+)",
|
|
149
|
+
"${minor}": r"(?P<minor>\d+)",
|
|
150
|
+
"${patch}": r"(?P<patch>\d+)",
|
|
151
|
+
"${prerelease}": r"(?P<prerelease>\w+\d+)?",
|
|
152
|
+
"${devrelease}": r"(?P<devrelease>\.dev\d+)?",
|
|
153
|
+
}
|
|
@@ -3,6 +3,7 @@ from __future__ import annotations
|
|
|
3
3
|
import re
|
|
4
4
|
from typing import Callable
|
|
5
5
|
|
|
6
|
+
from commitizen.defaults import get_tag_regexes
|
|
6
7
|
from commitizen.git import get_tags
|
|
7
8
|
from commitizen.providers.base_provider import VersionProvider
|
|
8
9
|
from commitizen.version_schemes import (
|
|
@@ -22,14 +23,7 @@ class ScmProvider(VersionProvider):
|
|
|
22
23
|
It is meant for `setuptools-scm` or any package manager `*-scm` provider.
|
|
23
24
|
"""
|
|
24
25
|
|
|
25
|
-
TAG_FORMAT_REGEXS =
|
|
26
|
-
"$version": r"(?P<version>.+)",
|
|
27
|
-
"$major": r"(?P<major>\d+)",
|
|
28
|
-
"$minor": r"(?P<minor>\d+)",
|
|
29
|
-
"$patch": r"(?P<patch>\d+)",
|
|
30
|
-
"$prerelease": r"(?P<prerelease>\w+\d+)?",
|
|
31
|
-
"$devrelease": r"(?P<devrelease>\.dev\d+)?",
|
|
32
|
-
}
|
|
26
|
+
TAG_FORMAT_REGEXS = get_tag_regexes(r"(?P<version>.+)")
|
|
33
27
|
|
|
34
28
|
def _tag_format_matcher(self) -> Callable[[str], VersionProtocol | None]:
|
|
35
29
|
version_scheme = get_version_scheme(self.config)
|
|
@@ -46,10 +46,18 @@ descriptive commits.
|
|
|
46
46
|
|
|
47
47
|
## Installation
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
Install commitizen in your system using `pipx` (Recommended, <https://pypa.github.io/pipx/installation/>):
|
|
50
50
|
|
|
51
51
|
```bash
|
|
52
|
-
|
|
52
|
+
pipx ensurepath
|
|
53
|
+
pipx install commitizen
|
|
54
|
+
pipx upgrade commitizen
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Install commitizen using `pip` with `--user` flag:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
pip install --user -U commitizen
|
|
53
61
|
```
|
|
54
62
|
|
|
55
63
|
### Python project
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
[tool.commitizen]
|
|
2
|
-
version = "3.29.
|
|
2
|
+
version = "3.29.1"
|
|
3
3
|
tag_format = "v$version"
|
|
4
4
|
version_files = [
|
|
5
5
|
"pyproject.toml:version",
|
|
@@ -9,7 +9,7 @@ version_files = [
|
|
|
9
9
|
|
|
10
10
|
[tool.poetry]
|
|
11
11
|
name = "commitizen"
|
|
12
|
-
version = "3.29.
|
|
12
|
+
version = "3.29.1"
|
|
13
13
|
description = "Python commitizen client tool"
|
|
14
14
|
authors = ["Santiago Fraire <santiwilly@gmail.com>"]
|
|
15
15
|
license = "MIT"
|
|
@@ -64,7 +64,7 @@ pytest-regressions = "^2.4.0"
|
|
|
64
64
|
pytest-freezer = "^0.4.6"
|
|
65
65
|
pytest-xdist = "^3.1.0"
|
|
66
66
|
# linter
|
|
67
|
-
ruff = ">=0.5.0,<0.
|
|
67
|
+
ruff = ">=0.5.0,<0.7.0"
|
|
68
68
|
pre-commit = ">=2.18,<4.0"
|
|
69
69
|
mypy = "^1.4"
|
|
70
70
|
types-PyYAML = ">=5.4.3,<7.0.0"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "3.29.0"
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
from __future__ import annotations
|
|
2
|
-
|
|
3
|
-
import re
|
|
4
|
-
|
|
5
|
-
from .base import BaseFormat
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
class Textile(BaseFormat):
|
|
9
|
-
extension = "textile"
|
|
10
|
-
|
|
11
|
-
RE_TITLE = re.compile(r"^h(?P<level>\d)\. (?P<title>.*)$")
|
|
12
|
-
|
|
13
|
-
def parse_version_from_title(self, line: str) -> str | None:
|
|
14
|
-
if not self.RE_TITLE.match(line):
|
|
15
|
-
return None
|
|
16
|
-
m = re.search(self.version_parser, line)
|
|
17
|
-
if not m:
|
|
18
|
-
return None
|
|
19
|
-
return m.group("version")
|
|
20
|
-
|
|
21
|
-
def parse_title_level(self, line: str) -> int | None:
|
|
22
|
-
m = self.RE_TITLE.match(line)
|
|
23
|
-
if not m:
|
|
24
|
-
return None
|
|
25
|
-
return int(m.group("level"))
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{commitizen-3.29.0 → commitizen-3.29.1}/commitizen/cz/conventional_commits/conventional_commits.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|