From 68da4a6fd4a666f51d328c311dcc0c2e5659b39a Mon Sep 17 00:00:00 2001 From: Ondrej Nosek Date: Jan 21 2020 12:54:41 +0000 Subject: module-build optional key help Enhances help for module-build command regarding option "optional" that allows undocumented values. These values are passed to MBS and processed there, therefore a proper link to a MBS description is provided. Fixes: https://pagure.io/fedpkg/issue/280 Signed-off-by: Ondrej Nosek --- diff --git a/pyrpkg/cli.py b/pyrpkg/cli.py index b199398..2ee0243 100644 --- a/pyrpkg/cli.py +++ b/pyrpkg/cli.py @@ -1152,10 +1152,15 @@ class cliClient(object): '--requires', action='append', metavar='name:stream', dest='requires', type=utils.validate_module_dep_override, help='Requires to override in the form of "name:stream"') + optional_help_msg = ( + 'MBS optional arguments in the form of "key=value". For example: ' + "'{0} module-build --optional \"reuse_components_from=\"'. " + "More description including list of available arguments here: " + "https://pagure.io/fm-orchestrator/") parser.add_argument( '--optional', action='append', metavar='key=value', dest='optional', type=utils.validate_module_build_optional, - help='MBS optional arguments in the form of "key=value"') + help=optional_help_msg.format(self.name)) parser.add_argument( '--file', nargs='?', dest='file_path', help='The modulemd yaml file for module scratch build.')