I recently used pipx to install a package (That was the recommended install approach for the package). I installed using pip in a virtual environment. I was with the assumption that pipx is in that environment, and then pipx would install the package in the same environment. However, pipx created a environment folder and installed the package there. I had to add the PATH into in order to use that package. This led me to think what the difference between pipx and using pip install inside a virtual environment
Isn't using pip from the virtual environment more convenient to install the package ?
pipx
you don't need to add every virtual env to$PATH
, you only need to add$HOME/.local/bin
once (but you're recommended to add this anyway for other needs likepip install --user
). – Heterolecithalpipx
creates a virtual env, installs the application and its dependecies and links the application into$HOME/.local/bin
, all automatically, with just one commandpipx install <app>
. Withpip
you need to do everything manually and add it to$PATH
yourself. – Heterolecithal