Exemplo n.º 1
0
 def interscript_from_options(self,*args):
   "Run interscript from with the given command line options"
   from interscript  import run_from_options
   svdin  = sys.stdin
   try:
     try:
       run_from_options(args)
     except KeyboardInterrupt: raise
     except SystemExit: raise
     except:
       print('Error running embedded interscript from options')
       print('options were', args)
       traceback.print_exc()
   finally:
     sys.stdin  = svdin
Exemplo n.º 2
0
 def interscript_from_options(self, *args):
     "Run interscript from with the given command line options"
     from interscript import run_from_options
     svdin = sys.stdin
     try:
         try:
             run_from_options(args)
         except KeyboardInterrupt:
             raise
         except SystemExit:
             raise
         except:
             print('Error running embedded interscript from options')
             print('options were', args)
             traceback.print_exc()
     finally:
         sys.stdin = svdin
Exemplo n.º 3
0
#!/usr/bin/env python
import sys
args = sys.argv[1:]
if sys.path[0]!='':
  sys.path = ['']+ sys.path

import interscript
interscript.run_from_options(args)