shiv icon indicating copy to clipboard operation
shiv copied to clipboard

use the python interpreter (to set the shebang line) when running pip

Open sdementen opened this issue 2 years ago • 2 comments

To allow to shiv packages for different versions of python (e.g. 3.8, 3.9, 3.10) from a single version of python (e.g. 3.8) in which shiv is installed, it would be practical to use the python interpreter to use in the shebang line as the python interpreter to use in the "python -m pip install --target ..."

sdementen avatar May 22 '22 07:05 sdementen

hi @sdementen, this is an interesting suggestion and one I'm open to, however I would prefer that it be explicit rather than implicit.. perhaps as a flag? --pip-interpreter or --pip-path ?

lorencarvalho avatar Jul 09 '22 18:07 lorencarvalho

Yes indeed. If not from backward incompatibilities, I would have set it as the default as it is the more natural. Maybe add a warning for the default case if the version of the two python interpreters (target and runtime) are not the same

sdementen avatar Jul 10 '22 13:07 sdementen