In the Packages/User
folder, create the SublimeREPL/config/Python/
folders and the Main.sublime-menu
folder with the following content (format json
), where in "cmd"
line you will change the /path/to/Anaconda/python
by the correct path to the% Anaconda
on your computer. This will create two more options in SublimeREPL, one for the Anaconda Python and one for the Anaconda iPython.
[
{
"id": "tools",
"children":
[{
"caption": "SublimeREPL",
"mnemonic": "r",
"id": "SublimeREPL",
"children":
[
{
"caption": "Python",
"id": "Python",
"children":[
{
"command": "repl_open",
"caption": "Python - Anaconda",
"id": "repl_python",
"mnemonic": "p",
"args": {
"type": "subprocess",
"encoding": "utf8",
"cmd": ["/path/to/Anaconda/python", "-i", "-u"],
"cwd": "$file_path",
"syntax": "Packages/Python/Python.tmLanguage",
"external_id": "python",
"extend_env": {"PYTHONIOENCODING": "utf-8"}
}
},
{
"command": "repl_open",
"caption": "IPython - Anaconda",
"id": "repl_python_ipython",
"mnemonic": "p",
"args": {
"type": "subprocess",
"encoding": "utf8",
"autocomplete_server": true,
"cmd": ["/path/to/Anaconda/python", "-u", "${packages}/SublimeREPL/config/Python/ipy_repl.py"],
"cwd": "$file_path",
"syntax": "Packages/Python/Python.tmLanguage",
"external_id": "python",
"extend_env": {
"PYTHONIOENCODING": "utf-8",
"SUBLIMEREPL_EDITOR": "$editor"
}
}
}
]
}
]
}]
}
Source: this SOEN response.