The help entry for --quiet had been added to list-fragments rather than
enable-fragment.

Due to the fact that --quiet is a global option, this actually adds a
dummy --quiet option as it would otherwise hide the global option, but
would never be set since any --quiet argument would already have been
parsed when this option is parsed.

Signed-off-by: Peter Kjellerstedt <[email protected]>
---

PATCHv2: No changes.

 meta/lib/bbconfigbuild/configfragments.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/lib/bbconfigbuild/configfragments.py 
b/meta/lib/bbconfigbuild/configfragments.py
index 6fdac33a5d..f79e238297 100644
--- a/meta/lib/bbconfigbuild/configfragments.py
+++ b/meta/lib/bbconfigbuild/configfragments.py
@@ -197,7 +197,9 @@ class ConfigFragmentsPlugin(LayerPlugin):
 
         parser_enable_fragment = self.add_command(sp, 'enable-fragment', 
self.do_enable_fragment, parserecipes=False)
         parser_enable_fragment.add_argument("--confpath", 
default=default_confpath, help='Configuration file which contains a list of 
enabled fragments (default is {}).'.format(default_confpath))
-        parser_list_fragments.add_argument('--quiet', '-q', 
action='store_true', help='Do not print descriptions of the newly enabled 
fragments')
+        # Store the quiet argument in quiet_dummy. This is because --quiet is a
+        # global option and this one is only here to add an entry for --help.
+        parser_enable_fragment.add_argument('--quiet', '-q', 
action='store_true', dest='quiet_dummy', help='Do not print descriptions of the 
newly enabled fragments')
         parser_enable_fragment.add_argument('fragmentname', help='The name of 
the fragment (use list-fragments to see them)', nargs='+')
 
         parser_disable_fragment = self.add_command(sp, 'disable-fragment', 
self.do_disable_fragment, parserecipes=False)
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#226682): 
https://lists.openembedded.org/g/openembedded-core/message/226682
Mute This Topic: https://lists.openembedded.org/mt/116407149/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to