parent
153c9bd539
commit
1b9879ccbf
1 changed files with 4 additions and 2 deletions
|
@ -78,6 +78,10 @@ class InventoryCLI(CLI):
|
|||
basedir_opts=True,
|
||||
)
|
||||
|
||||
# remove unused default options
|
||||
self.parser.remove_option('--limit')
|
||||
self.parser.remove_option('--list-hosts')
|
||||
|
||||
# Actions
|
||||
action_group = optparse.OptionGroup(self.parser, "Actions", "One of following must be used on invocation, ONLY ONE!")
|
||||
action_group.add_option("--list", action="store_true", default=False, dest='list', help='Output all hosts info, works as inventory script')
|
||||
|
@ -86,8 +90,6 @@ class InventoryCLI(CLI):
|
|||
help='create inventory graph, if supplying pattern it must be a valid group name')
|
||||
self.parser.add_option_group(action_group)
|
||||
|
||||
# Options
|
||||
|
||||
# graph
|
||||
self.parser.add_option("-y", "--yaml", action="store_true", default=False, dest='yaml',
|
||||
help='Use YAML format instead of default JSON, ignored for --graph')
|
||||
|
|
Loading…
Reference in a new issue