diff options
Diffstat (limited to 'bitbake/bin/bitbake-layers')
-rwxr-xr-x | bitbake/bin/bitbake-layers | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/bitbake/bin/bitbake-layers b/bitbake/bin/bitbake-layers index b4cfd5506a..fd1ebfbeb3 100755 --- a/bitbake/bin/bitbake-layers +++ b/bitbake/bin/bitbake-layers | |||
@@ -38,6 +38,8 @@ def main(args): | |||
38 | 38 | ||
39 | cmds = Commands(initialenv) | 39 | cmds = Commands(initialenv) |
40 | if args: | 40 | if args: |
41 | # Allow user to specify e.g. show-layers instead of show_layers | ||
42 | args = [args[0].replace('-', '_')] + args[1:] | ||
41 | cmds.onecmd(' '.join(args)) | 43 | cmds.onecmd(' '.join(args)) |
42 | else: | 44 | else: |
43 | cmds.do_help('') | 45 | cmds.do_help('') |
@@ -90,14 +92,14 @@ class Commands(cmd.Cmd): | |||
90 | """display general help or help on a specified command""" | 92 | """display general help or help on a specified command""" |
91 | if topic: | 93 | if topic: |
92 | sys.stdout.write('%s: ' % topic) | 94 | sys.stdout.write('%s: ' % topic) |
93 | cmd.Cmd.do_help(self,topic) | 95 | cmd.Cmd.do_help(self, topic.replace('-', '_')) |
94 | else: | 96 | else: |
95 | sys.stdout.write("usage: bitbake-layers <command> [arguments]\n\n") | 97 | sys.stdout.write("usage: bitbake-layers <command> [arguments]\n\n") |
96 | sys.stdout.write("Available commands:\n") | 98 | sys.stdout.write("Available commands:\n") |
97 | procnames = self.get_names() | 99 | procnames = self.get_names() |
98 | for procname in procnames: | 100 | for procname in procnames: |
99 | if procname[:3] == 'do_': | 101 | if procname[:3] == 'do_': |
100 | sys.stdout.write(" %s\n" % procname[3:]) | 102 | sys.stdout.write(" %s\n" % procname[3:].replace('_', '-')) |
101 | doc = getattr(self, procname).__doc__ | 103 | doc = getattr(self, procname).__doc__ |
102 | if doc: | 104 | if doc: |
103 | sys.stdout.write(" %s\n" % doc.splitlines()[0]) | 105 | sys.stdout.write(" %s\n" % doc.splitlines()[0]) |
@@ -123,7 +125,7 @@ class Commands(cmd.Cmd): | |||
123 | def do_show_overlayed(self, args): | 125 | def do_show_overlayed(self, args): |
124 | """list overlayed recipes (where there is a recipe in another layer that has a higher layer priority) | 126 | """list overlayed recipes (where there is a recipe in another layer that has a higher layer priority) |
125 | 127 | ||
126 | usage: show_overlayed | 128 | usage: show-overlayed |
127 | 129 | ||
128 | Highest priority recipes are listed with the recipes they overlay as subitems. | 130 | Highest priority recipes are listed with the recipes they overlay as subitems. |
129 | """ | 131 | """ |
@@ -194,7 +196,7 @@ build results (as the layer priority order has effectively changed). | |||
194 | 196 | ||
195 | for layername in layernames: | 197 | for layername in layernames: |
196 | if not layername in found_layernames: | 198 | if not layername in found_layernames: |
197 | logger.error('Unable to find layer %s in current configuration, please run "%s show_layers" to list configured layers' % (layername, os.path.basename(sys.argv[0]))) | 199 | logger.error('Unable to find layer %s in current configuration, please run "%s show-layers" to list configured layers' % (layername, os.path.basename(sys.argv[0]))) |
198 | return | 200 | return |
199 | layers = found_layerdirs | 201 | layers = found_layerdirs |
200 | else: | 202 | else: |
@@ -313,7 +315,7 @@ build results (as the layer priority order has effectively changed). | |||
313 | def do_show_appends(self, args): | 315 | def do_show_appends(self, args): |
314 | """list bbappend files and recipe files they apply to | 316 | """list bbappend files and recipe files they apply to |
315 | 317 | ||
316 | usage: show_appends | 318 | usage: show-appends |
317 | 319 | ||
318 | Recipes are listed with the bbappends that apply to them as subitems. | 320 | Recipes are listed with the bbappends that apply to them as subitems. |
319 | """ | 321 | """ |