Ask Your Question

Revision history [back]

Sage uses its own version of ipython with its own startup files. Those startup files should be under $DOT_SAGE/ipython-X.Y.Z/ ; so for me, the interesting directory is in ~/.sage/ipython-5.0.0/profile_default/ . There was no ipython_config.py file in there, so I copied it from the .ipython directory.

So here is what I did to get vi keybindings to work:

  1. Get vi keybindings to work in ipython by adding the line c.TerminalInteractiveShell.editing_mode = 'vi' to .ipython/profile_default/ipython_config.py
  2. cp -n ~/.ipython/profile_default/ipython_config.py ~/.sage/ipython-5.0.0/profile_default/