Skip to content

Commit 0488175

Browse files
committed
feat(config): add ignore_bump_sha_list and ignore_bump_author_list to Settings
1 parent d82dd5a commit 0488175

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

commitizen/commands/bump.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,10 @@ def __init__(self, config: BaseConfig, arguments: BumpArgs) -> None:
104104
self.retry = arguments["retry"]
105105
self.pre_bump_hooks = self.config.settings["pre_bump_hooks"]
106106
self.post_bump_hooks = self.config.settings["post_bump_hooks"]
107+
self.ignore_bump_sha_list = self.config.settings.get("ignore_bump_sha_list")
108+
self.ignore_bump_author_list = self.config.settings.get(
109+
"ignore_bump_author_list"
110+
)
107111
deprecated_version_type = arguments.get("version_type")
108112
if deprecated_version_type:
109113
warnings.warn(
@@ -162,6 +166,8 @@ def _find_increment(self, commits: list[git.GitCommit]) -> Increment | None:
162166
commits,
163167
regex=bump_pattern,
164168
increments_map=bump_map,
169+
ignore_bump_sha_list=self.ignore_bump_sha_list,
170+
ignore_bump_author_list=self.ignore_bump_author_list,
165171
)
166172

167173
def _validate_arguments(self, current_version: VersionProtocol) -> None:

commitizen/defaults.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@ class Settings(TypedDict, total=False):
6565
version_type: str | None
6666
version: str | None
6767
breaking_change_exclamation_in_title: bool
68+
ignore_bump_sha_list: list[str] | None
69+
ignore_bump_author_list: list[str] | None
6870

6971

7072
CONFIG_FILES: tuple[str, ...] = (

0 commit comments

Comments
 (0)