8 sys.path.insert(0,os.path.abspath(os.path.join(__file__,'../../lib')))
12 usage = """usage: %prog [-s|--versions] COMMAND [ARGS]
14 Wizard is a Git-based autoinstall management system for scripts.
17 info Reports information about an autoinstall
18 massmigrate Performs mass migration of autoinstalls of an application
19 migrate Migrate autoinstalls from old format to Git-based format
20 summary Generate statistics about autoinstalls
22 See '%prog help COMMAND' for more information on a specific command."""
24 parser = optparse.OptionParser(usage)
25 parser.disable_interspersed_args()
26 parser.add_option("-s", "--versions", dest="versions",
27 default="/afs/athena.mit.edu/contrib/scripts/sec-tools/store/versions",
28 help="Location of parallel-find output directory, or a file containing a newline separated list of 'all autoinstalls' (for testing).")
29 # Find the end of the "global" options
30 options, args = parser.parse_args()
32 command = args[0] # shouldn't fail
35 getattr(wizard.command, rest_argv[0]).main(['-h'], options)
36 except AttributeError:
37 parser.error("invalid action")
43 command_module = getattr(wizard.command, command)
44 except AttributeError:
45 parser.error("invalid action")
46 command_module.main(rest_argv, options)
48 if __name__ == "__main__":