News for hackers. Stuff that matters.
Re:Pyenv – lets you easily switch between multiple versions ... by airstrike on Monday March 25, 2024 @12:13PM (#39818125)
You only need pip and virtualenvwrapper

requirements.txt is a text file, not a separate tool...

if you want your program to work exactly as intended in the future, there are tools like py2exe and py2app for that.

Re:Pyenv – lets you easily switch between multiple versions ... by mixmastamyk on Monday March 25, 2024 @12:57PM (#39818638)
Don't need any wrappers either. venv has been built into python for ages.
Re:Pyenv – lets you easily switch between multiple versions ... by airstrike on Monday March 25, 2024 @01:07PM (#39818758)
yes but `workon` is too good not to have
Re:Pyenv – lets you easily switch between multiple versions ... by mixmastamyk on Monday March 25, 2024 @01:26PM (#39819004)
Looks like what could be a shell alias to cd and activate? I always keep a few tabs open to my repos folder, so not sure it would help me much. Doesn't seem to support fish, though activate does.
Re:Pyenv – lets you easily switch between multiple versions ... by physicles on Monday March 25, 2024 @08:09PM (#39822785)
I modified my bash prompt to detect and auto-activate Python environments, and show if one is currently active. Haven’t thought about activate in years. It’s great.
Re:Pyenv – lets you easily switch between multiple versions ... by mixmastamyk on Monday March 25, 2024 @11:11PM (#39823949)
Yes, I did that on my work laptop with fish, since I only ever used it with the work project.

On my personal machine I don't bother with venvs, so also haven't thought about it in years. But was trying to figure out what the "workon" command did for GP.

Re:Pyenv – lets you easily switch between multiple versions ... by airstrike on Tuesday March 26, 2024 @01:20PM (#39830402)
`workon` lists all virtualenvs you have in your virtualenvs folder and `workon foo` activates environment foo

this way I have all my envs in ~/virtual and all my projects in ~/projects and just `workon xyz` when I want to be in a certain venv for a given project (which doesn't always map one-to-one)