How to execute the current line in Sublime Text 2? Or, IDE that allows execution of the current line in Python

4

No (IDE for

asked by anonymous 09.03.2014 / 17:05

1 answer

3

Yes, it is possible with the package SublimeREPL , which allows you to run interpreters of different languages within the editor itself.

Open a Python interpreter ( Tools > SublimeREPL > Python > Python ) and a Python source file. I usually use two columns, leaving the code in one and the interpreter in another. Place the cursor on the line you want to run and choose Tools > SublimeREPL > Eval in REPL > Lines (or press ctrl and , simultaneously, then release and then press the lowercase L key). Ready, the line will be executed in the interpreter.

This is not so convenient because the cursor does not automatically go to the next line and because there are different commands and shortcut keys to send the current line and to send the selected text. For R, the Enhanced-R package addresses these issues. I do not know if there is anything similar for Python.

    
09.03.2014 / 17:18