From 650d748757694366c0b5fc08ba6ccb97361162d9 Mon Sep 17 00:00:00 2001 From: Tomas Kopecek Date: Aug 28 2019 13:00:36 +0000 Subject: PR#1623: Extend help message to clarify clone-tag usage Merges #1623 https://pagure.io/koji/pull-request/1623 --- diff --git a/cli/koji_cli/commands.py b/cli/koji_cli/commands.py index c1f84ea..19058ea 100644 --- a/cli/koji_cli/commands.py +++ b/cli/koji_cli/commands.py @@ -3282,6 +3282,7 @@ def anon_handle_hostinfo(goptions, session, args): def handle_clone_tag(goptions, session, args): "[admin] Duplicate the contents of one tag onto another tag" usage = _("usage: %prog clone-tag [options] ") + usage += _("\nclone-tag will create the destination tag if it does not already exist") usage += _("\n(Specify the --help global option for a list of other help options)") parser = OptionParser(usage=usage) parser.add_option('--config', action='store_true', diff --git a/tests/test_cli/test_clone_tag.py b/tests/test_cli/test_clone_tag.py index d243330..e639749 100644 --- a/tests/test_cli/test_clone_tag.py +++ b/tests/test_cli/test_clone_tag.py @@ -29,6 +29,7 @@ class TestCloneTag(utils.CliTestCase): 'koji_cli.commands.activate_session').start() self.error_format = """Usage: %s clone-tag [options] +clone-tag will create the destination tag if it does not already exist (Specify the --help global option for a list of other help options) %s: error: {message} @@ -615,6 +616,7 @@ List of changes: self.assert_help( handle_clone_tag, """Usage: %s clone-tag [options] +clone-tag will create the destination tag if it does not already exist (Specify the --help global option for a list of other help options) Options: