shiv icon indicating copy to clipboard operation
shiv copied to clipboard

Expose building an archive as an API

Open moshez opened this issue 7 years ago • 4 comments

I have a wrapper for building executables that I would like to move from pex to shiv. However, the API to build executables is not exposed. It seems like starting around the with Temporary.... would be a good place to split up and call an API function.

Would that make sense as a PR?

moshez avatar Jun 07 '18 01:06 moshez

cc @warsaw

moshez avatar Jun 07 '18 01:06 moshez

hi @moshez !

this would be a welcome contribution, (or I'd be happy to take a crack at it as well). I think stylistically it'd be best to move everything except the click entrypoint out of cli.py and into it's own module. I'd suggest builder.py but I'd like to keep that untouched since the logic there is cribbed from zipapp (so I don't want to clutter it), perhaps builder.py could be renamed zipapp.py and then the archive creation functions could be placed into a builder.py?

lorencarvalho avatar Jun 07 '18 03:06 lorencarvalho

No need to CC me, I get all notifications. Oh, and +1!

warsaw avatar Jun 08 '18 00:06 warsaw

Sounds good, I should have some time next week to prototype a PR.

moshez avatar Jun 08 '18 01:06 moshez