allow -R ...pyc, fixed issue 1186, thanks Corne.Dickens

This commit is contained in:
mdipierro
2012-11-29 18:21:06 -06:00
parent ef8f10c42d
commit 568c33d7d6
3 changed files with 11 additions and 5 deletions
+7 -1
View File
@@ -220,7 +220,13 @@ def run(
_env.update(exec_pythonrc())
if startfile:
try:
execfile(startfile, _env)
ccode = None
if startfile.endswith('.pyc'):
ccode = read_pyc(startfile)
exec ccode in _env
else:
execfile(startfile, _env)
if import_models:
BaseAdapter.close_all_instances('commit')
except Exception, e: