cli_options
Shared Click option decorators for bump-my-version commands.
Module-level constants cover options that are identical across every command that uses them. Factory functions are provided for options whose type or default intentionally differs between commands, so divergence cannot happen silently.
Functions¶
ignore_missing_files_option
¶
ignore_missing_files_option(
is_flag: bool = False,
) -> Callable
Return the --ignore-missing-files Click option decorator.
Parameters:
is_flag-
When
True, returns a simple boolean flag with no--no-counterpart (used by thereplacecommand). WhenFalse(default), returns a tri-state--flag/--no-flagoption whose default isNone, letting the config-file value win when the flag is omitted (used by thebumpcommand).TYPE:
boolDEFAULT:
False
Returns:
-
Callable -
A Click option decorator ready to be applied with
@.
ignore_missing_version_option
¶
ignore_missing_version_option(
is_flag: bool = False,
) -> Callable
Return the --ignore-missing-version Click option decorator.
Parameters:
is_flag-
When
True, returns a simple boolean flag with no--no-counterpart (used by thereplacecommand). WhenFalse(default), returns a tri-state--flag/--no-flagoption whose default isNone, letting the config-file value win when the flag is omitted (used by thebumpcommand).TYPE:
boolDEFAULT:
False
Returns:
-
Callable -
A Click option decorator ready to be applied with
@.