From a3ddae7416984e06cc24c80ad911a3cb0dc0cd79 Mon Sep 17 00:00:00 2001 From: Louis Abel Date: Tue, 20 Dec 2022 02:17:56 -0700 Subject: [PATCH] general quick-bump cleanup and additional opts --- mangle/quick-bump.py | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/mangle/quick-bump.py b/mangle/quick-bump.py index 7d45f72..e44d6eb 100755 --- a/mangle/quick-bump.py +++ b/mangle/quick-bump.py @@ -8,10 +8,11 @@ import os import subprocess import sys import argparse -import subprocess parser = argparse.ArgumentParser() -parser.add_argument("--pkg", help="Package name to bump (can be comma delimited list)", required=True) +parser.add_argument("--pkg", + help="Package name to bump (can be comma delimited list)", + required=True) parser.add_argument("--branch", help="Package branch", required=True) parser.add_argument("--sig", help="Name of SIG that holds this package") parser.add_argument("--peridot-import", help="Tell peridot to import", @@ -31,15 +32,21 @@ parser.add_argument("--peridot-client-id", parser.add_argument("--peridot-client-secret", help="Peridot client secret (PERIDOT_CLIENT_SECRET)", required=False) -parser.add_argument("--dry", help="Do a dry bump for testing", +parser.add_argument("--dry",help="Do a dry bump for testing", required=False, action='store_true') parser.add_argument("--git-user", default="Release Engineering") parser.add_argument("--git-email", default="releng@rockylinux.org") +parser.add_argument("--change-user", + help="Sets the user for the rpm changelog (first last )", + default="Release Engineering ") +parser.add_argument("--change-comment", + help="Sets the comment that will appear in the changelog and commit message", + default="Release tag bump for rebuild (https://sig-core.rocky.page/rebuild/)") -args = parser.parse_args() -user = 'Release Engineering ' -comment = 'Release tag bump for rebuild (https://sig-core.rocky.page/rebuild/)' +args = parser.parse_args(args=None if sys.argv[1:] else ['--help']) +user = args.change_user +comment = args.change_comment if args.peridot_import: peridot_api_endpoint = os.environ.get('PERIDOT_ENDPOINT') or args.peridot_endpoint