mod/webui/createdb.py
Go to the documentation of this file.
1 #! /usr/bin/env python
2 
3 """
4 usage: %(progname)s
5 """
6 
7 
8 import os, sys, string, time, getopt
9 
10 PKG = 'webui' # this package name
11 import roslib; roslib.load_manifest(PKG)
12 
13 from pyclearsilver.log import *
14 
15 import db_webui
16 
17 def test():
18  pass
19 
20 def usage(progname):
21  print __doc__ % vars()
22 
23 def main(argv, stdout, environ):
24  progname = argv[0]
25  optlist, args = getopt.getopt(argv[1:], "", ["help", "test", "debug"])
26 
27  testflag = 0
28 
29  for (field, val) in optlist:
30  if field == "--help":
31  usage(progname)
32  return
33  elif field == "--debug":
34  debugfull()
35  elif field == "--test":
36  testflag = 1
37 
38  if testflag:
39  test()
40  return
41 
42  db = db_webui.initSchema(create=1)
43 
44 if __name__ == "__main__":
45  main(sys.argv, sys.stdout, os.environ)
def main(argv, stdout, environ)


webui
Author(s): Scott Hassan
autogenerated on Mon Jun 10 2019 15:51:24