__all__ = [ 'options', 'arguments', 'main' ]
-def print_list(items, indent=4):
- line = ' ' * indent
- for i,item in enumerate(items):
- if len(line) + len(item) > 76:
- print line
- line = ' ' * indent
-
- if i < len(items) - 1:
- line += '%s, ' % item
- else:
- line += item
- print line
-
usage="%prog [m5 options] script.py [script options]"
version="%prog 2.0"
brief_copyright='''
import internal
import traceflags as flags
+import util
from internal.trace import clear, output, set, ignore
def help():
print "Base Flags:"
- for flag in trace.flags.basic:
- print " %s: %s" % (flag, trace.flags.descriptions[flag])
+ for flag in flags.basic:
+ print " %s: %s" % (flag, flags.descriptions[flag])
print
print "Compound Flags:"
- for flag in trace.flags.compound:
+ for flag in flags.compound:
if flag == 'All':
continue
- print " %s: %s" % (flag, trace.flags.descriptions[flag])
- print_list(trace.flags.compoundMap[flag], indent=8)
+ print " %s: %s" % (flag, flags.descriptions[flag])
+ util.print_list(flags.compoundMap[flag], indent=8)
print
from misc import *
from multidict import multidict
import jobfile
+
+def print_list(items, indent=4):
+ line = ' ' * indent
+ for i,item in enumerate(items):
+ if len(line) + len(item) > 76:
+ print line
+ line = ' ' * indent
+
+ if i < len(items) - 1:
+ line += '%s, ' % item
+ else:
+ line += item
+ print line