I have two versions of Python and I have REPL in Sublime Text 2 but I only get one version of Python.
How can I do to be able to choose between both versions?
I have two versions of Python and I have REPL in Sublime Text 2 but I only get one version of Python.
How can I do to be able to choose between both versions?
You're accessing Tools
> Build System
> New Build System
:
And you put the following code (this would be to put version 3 of Python):
{
"cmd": ["python3", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python"
}
You save and you already have a new build.
The code to put any version of Python, is the same but putting the absolute path (both in GNU / Linux and Windows):
{
"cmd": ["C:\path\to\desired\version\python.exe", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python"
}
In GNU the path would be something like /usr/bin/Python...