def main():
parser = create_parser()
args = parser.parse_args()
# Arguments that drive the behaviour of pyorcy
pyorcy.USE_CYTHON = True
if args.python:
pyorcy.USE_CYTHON = False
if args.verbose:
pyorcy.VERBOSE = True
# Add the location of the module to the sys.path
module = args.MODULE[0]
sys.path.append(os.path.dirname(module))
# Add remaining parameters in globals
init_globals = {'__args__': args.mod_args}
# Execute the module
runpy.run_path(module, init_globals=init_globals, run_name="__main__")
评论列表
文章目录