19 from formatter
import *
24 import sys, os, time, string, glob, getopt
28 print "\nDocMaker Usage information\n" 29 print " docmaker [options] file1 [file2 ...]\n" 30 print "using the following options:\n" 31 print " -h : print this page" 32 print " -t : set project title, as in '-t \"My Project\"'" 33 print " -o : set output directory, as in '-o mydir'" 34 print " -p : set documentation prefix, as in '-p ft2'" 36 print " --title : same as -t, as in '--title=\"My Project\"'" 37 print " --output : same as -o, as in '--output=mydir'" 38 print " --prefix : same as -p, as in '--prefix=ft2'" 42 """main program loop""" 47 opts, args = getopt.getopt( sys.argv[1:], \
49 [
"help",
"title=",
"output=",
"prefix="] )
50 except getopt.GetoptError:
60 project_title =
"Project" 65 if opt[0]
in (
"-h",
"--help" ):
69 if opt[0]
in (
"-t",
"--title" ):
70 project_title = opt[1]
72 if opt[0]
in (
"-o",
"--output" ):
73 utils.output_dir = opt[1]
75 if opt[0]
in (
"-p",
"--prefix" ):
76 project_prefix = opt[1]
86 for filename
in file_list:
87 source_processor.parse_file( filename )
88 content_processor.parse_sources( source_processor )
91 content_processor.finish()
93 formatter =
HtmlFormatter( content_processor, project_title, project_prefix )
96 formatter.index_dump()
97 formatter.section_dump_all()
102 if __name__ ==
'__main__':
def make_file_list(args=None)