def register_command_line(self, sub_parsers):

        #
        # Note - this is as-defined by ansible:
        # http://docs.ansible.com/developing_inventory.html
        #
        parser = sub_parsers.add_parser(
            'inventory', help='Print ansible inventory to stdout',
            description='Print ansible inventory to stdout.  The data '
                        'for the inventory comes from Servifile_globals.yml.  '
                        'This is used by the servi_inventory script.')

        parser.add_argument(
            '--list',  action='store_true',
            help='List all hosts')

        parser.add_argument(
            '--host', type=str,
            help='List specific host')

        parser.add_argument(
            '--debug', action="store_true",
            help="Debug your HOSTS record.")

        parser.set_defaults(command_func=self.run)

        self.parser = parser
        self.arglist = [arg.dest for arg in parser._optionals._actions
                        if arg.dest != 'help']
dataset/ETHPy150Open rr326/servi/servi/commands/inventory.py/InventoryCommand.register_command_line/original