Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit faef24e

Browse files
fix(commit): emit deprecated warning of cz commit -s
1 parent a9cd957 commit faef24e

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

‎commitizen/commands/commit.py‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,11 @@ def __call__(self) -> None:
125125
write_message_to_file = self.arguments.get("write_message_to_file")
126126
signoff = bool(self.arguments.get("signoff"))
127127

128+
if signoff:
129+
out.warn(
130+
"Deprecated warning: `cz commit -s` is deprecated and will be removed in v5, please use `cz commit -- -s` instead."
131+
)
132+
128133
if self.arguments.get("all"):
129134
git.add("-u")
130135

@@ -147,11 +152,6 @@ def __call__(self) -> None:
147152
if dry_run:
148153
raise DryRunExit()
149154

150-
if signoff:
151-
out.warn(
152-
"signoff mechanic is deprecated, please use `cz commit -- -s` instead."
153-
)
154-
155155
if self.config.settings["always_signoff"] or signoff:
156156
extra_args = f"{extra_args} -s".strip()
157157

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /