Module: lib.editorhooks¶
‘editor’ hooks for common editors that work well with ipython
They should honor the line number argument, at least.
Contributions are very welcome.
11 Functions¶
-
IPython.lib.editorhooks.install_editor(template, wait=False)¶ Installs the editor that is called by IPython for the %edit magic.
This overrides the default editor, which is generally set by your EDITOR environment variable or is notepad (windows) or vi (linux). By supplying a template string
run_template, you can control how the editor is invoked by IPython – (e.g. the format in which it accepts command line options)Parameters: - template (basestring) – run_template acts as a template for how your editor is invoked by the shell. It should contain ‘{filename}’, which will be replaced on invokation with the file name, and ‘{line}’, $line by line number (or 0) to invoke the file with.
- wait (bool) – If
waitis true, wait until the user presses enter before returning, to facilitate non-blocking editors that exit immediately after the call.
-
IPython.lib.editorhooks.komodo(exe='komodo')¶ Activestate Komodo [Edit]
-
IPython.lib.editorhooks.scite(exe='scite')¶ SciTE or Sc1
-
IPython.lib.editorhooks.notepadplusplus(exe='notepad++')¶ Notepad++ http://notepad-plus.sourceforge.net
-
IPython.lib.editorhooks.jed(exe='jed')¶ JED, the lightweight emacsish editor
-
IPython.lib.editorhooks.idle(exe='idle')¶ Idle, the editor bundled with python
Parameters: exe (str, None) – If none, should be pretty smart about finding the executable.
-
IPython.lib.editorhooks.mate(exe='mate')¶ TextMate, the missing editor
-
IPython.lib.editorhooks.emacs(exe='emacs')¶
-
IPython.lib.editorhooks.gnuclient(exe='gnuclient')¶
-
IPython.lib.editorhooks.crimson_editor(exe='cedt.exe')¶
-
IPython.lib.editorhooks.kate(exe='kate')¶