Add --no-rpmautospec option

Fixes #170.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2021-12-11 12:14:01 +01:00
parent 73f5d593c3
commit 8e8ae0c969

View file

@ -357,6 +357,8 @@ def main():
help="Store crate in current directory")
parser.add_argument("-a", "--rpmautospec", action="store_true",
help="Use autorelease and autochangelog features")
parser.add_argument("--no-rpmautospec", action="store_false",
help="Do not use rpmautospec")
parser.add_argument("--all-features", action="store_true",
help="Activate all available features")
parser.add_argument("--dynamic-buildrequires", action="store_true",
@ -436,7 +438,9 @@ def main():
kwargs["auto_changelog_entry"] = not args.no_auto_changelog_entry
rpmautospec = args.rpmautospec or detect_rpmautospec(default_target, spec_file)
rpmautospec = args.rpmautospec
if args.rpmautospec is None:
rpmautospec = detect_rpmautospec(default_target, spec_file)
kwargs["rpmautospec"] = rpmautospec
if args.target in {"fedora", "mageia", "opensuse"}: