Lines Matching refs:parser
386 parser = ConfigParser()
390 parser.read(filename)
391 for section in parser.sections():
392 parser.options(section)
397 val = parser.get(section,opt)
403 parser.__init__()
456 parser = FancyGetopt(toplevel_options + self.display_options)
457 parser.set_negative_aliases(self.negative_opt)
458 parser.set_aliases({'licence': 'license'})
459 args = parser.getopt(args=self.script_args, object=self)
460 option_order = parser.get_option_order()
467 args = self._parse_command_opts(parser, args)
478 self._show_help(parser,
501 def _parse_command_opts(self, parser, args):
503 'parser' must be a FancyGetopt instance; 'args' must be the list
560 parser.set_option_table(self.global_options +
563 parser.set_negative_aliases(negative_opt)
564 (args, opts) = parser.getopt(args[1:])
566 self._show_help(parser, display_options=0, commands=[cmd_class])
573 if hasattr(opts, parser.get_attr_name(help_option)):
607 def _show_help(self, parser, global_options=1, display_options=1,
610 several lists of command-line options. 'parser' should be a
630 parser.set_option_table(options)
631 parser.print_help(self.common_usage + "\nGlobal options:")
635 parser.set_option_table(self.display_options)
636 parser.print_help(
648 parser.set_option_table(klass.user_options +
651 parser.set_option_table(klass.user_options)
652 parser.print_help("Options for '%s' command:" % klass.__name__)