Hi!
I’m looking for an elegant solution for working with Python virtualenv. Does anyone have one? I’ve tried to search for one, but I haven’t found any that aren’t very hackish.
Best regards,
ultra
Hi!
I’m looking for an elegant solution for working with Python virtualenv. Does anyone have one? I’ve tried to search for one, but I haven’t found any that aren’t very hackish.
Best regards,
ultra
Hi
I’ve created a virtualenv for MyProject. When workon MyProject python 3.4 is used. When opening the project in ST3, python 2 is used.
I’ve changed my project settings to use:
“settings’”: {“python_interpreter”: “~/.virtualenv/MyProject/bin/python”}
If I cmd+B on a test.py file with print(sys.version_info) it still gives me python 2
Executing from the command line gives my python 3
What else do I need to change to make ST3 work with my virtualenv?
Kind regards
Jan
Apparently I needed to change my Build System to “Anaconda Python Builder” as well
Yes, you need to adjust the build for python. I suppose an auto-search plugin that looks for potential viertualenvs before defaulting to the standard interpreter is reasonable.
Here’s the build systems I wrote for virtualenvs. It will create them in the script directory if they don’t exist.