ofek / pyapp

Runtime installer for Python applications
https://ofek.dev/pyapp/
1.1k stars 24 forks source link

feature: management command to open a shell #130

Open axel-kah opened 1 month ago

axel-kah commented 1 month ago

Hi,

big fans of pyapp here. In its current form it lends itself very well for this use case: distribute lightweight, self-bootstrapping python environments based on lockfiles 💪

Icing on the cake would be an additional management command equivalent to the hatch env shell command: <pyapp-binary> self shell. Unfortunately no Rust skills beyond compiling existing projects to offer.

Tremeschin commented 1 month ago

I am also interested in this, we could have a wheel with many entry scripts created by uv/pip on the venv's bin directory, and start each project as if the person had bootstrapped Python, git cloned and installed the dependencies

And probably a PYAPP_{OPTION} to start the shell after the program exits, "shell mode"

I have a project similar to manim, so I always need a scene script file and a name as input, the no args behavior is to list the scenes on common dirs and quit, so the program "intantly crashes/does nothing" on a user's perspective

That's trivial for linux people, as they'd install from package managers and run on terminal, but not otherwise