On 24 February 2015 at 21:09, Ethan Furman <et...@stoneleaf.us> wrote: > Another way to support this is with subcommands. Have the default [implicit] > command be to create the zip app, and then > add any subcommands we need: > > python -m zipapp [create] foo #creates a foo.pyz from the foo directory > > python -m zipapp info foo.pyz # prints out shebang for foo.pyz > > python -m zipapp info --all foo.pyz # prints out shebang and directory > structure and files and .... > > This easily leaves the door open to add new commands in the future if any are > still needed, and makes the current > commands easy and simple to use.
I didn't know an implicit subcommand was allowed. That would work, although it does mean that you can't build a pyz from a directory "info" without explicitly using the create subcommand. I think I'm going to go with "python -m zipapp foo.pyz --info" (And an -o option for the target, mandatory when the source is a pyz file, and --python for the interpreter). It's not set in stone yet, so if anyone objects, there's still time to change my mind. Paul _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com