Lines Matching refs:FLAGS
33 """gflags2man runs a Google flags base program and generates a man page.
44 # This may seem a bit of an end run, but it: doesn't bloat flags, can
70 FLAGS = gflags.FLAGS
89 if FLAGS.v >= level: print msg
94 print >>sys.stderr, "flags:"
95 print >>sys.stderr, str(FLAGS)
157 module_c_re = re.compile(r'\s+Flags from (\S.+):$')
163 # "com.google.common.flags"
164 module_java_re = re.compile(r'\s+Flags for (\S.+):$')
181 self.modules = {} # { section_name(string), [ flags ] }
200 % (self.executable, FLAGS.help_flag))
205 [self.executable, FLAGS.help_flag])
211 % (self.name, FLAGS.help_flag,
235 start_line Line to start parsing flags on (int)
237 (-1, '') if the flags start could not be found
245 # Python flags start with 'flags:\n'
246 if ('flags:' == line
250 logging.debug('Flags start (python): %s' % line)
252 # SWIG flags just have the module name followed by colon.
254 logging.debug('Flags start (swig): %s' % line)
256 # C++ flags begin after a blank line and with a constant string
257 if after_blank and line.startswith(' Flags from '):
258 logging.debug('Flags start (c): %s' % line)
260 # java flags begin with a constant string
261 if line == 'where flags are':
262 logging.debug('Flags start (java): %s' % line)
263 start_line += 2 # skip "Standard flags:"
270 logging.warn('Never found the start of the flags section for "%s"!'
275 """Parse python/swig style flags."""
279 for line_num in range(start_line, len(self.output)): # collect flags
324 """Parse C style flags."""
328 for line_num in range(start_line, len(self.output)): # collect flags
330 if not line: # blank lines terminate flags
365 """Parse Java style flags (com.google.common.flags)."""
366 # The java flags prints starts with a "Standard flags" "module"
368 modname = 'Standard flags' # name of current module
374 for line_num in range(start_line, len(self.output)): # collect flags
435 """Base class to output flags information."""
498 # This shows flags in the original order
521 % (self.info.name, FLAGS.help_flag))
528 argv = FLAGS(argv) # handles help as well
539 doc = GenerateMan(prog, FLAGS.dest_dir)