After thinking about it some more, I suggest that instead of using a 
special option to execute a zipfile, we simply always get an importer 
for the script filename.  If the importer is imp.NullImporter, then 
we do normal script processing.  Otherwise, we set set sys.path[0] = 
sys.argv[0] = script, and import __main__.

This will support zipfiles and directories, Windows and Unix, even 
using "env" (since no option to the interpreter is required).

Thoughts?

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to