[IPython-dev] CodeMirror Vim keymaps (ipython-notebook 3.1)

Francisco de la Pena frandelapena at gmail.com
Fri Apr 24 13:00:56 EDT 2015


Unfortunately it seems that Vimception does not yet work with IPython 3.
See https://github.com/ivanov/ipython-vimception/issues/19 .

Francisco

On Fri, 2015-04-24 at 09:57 -0700, Thomas Kluyver wrote:
> Hi David,
> 
> 
> 
> You might want to look at Paul Ivanov's Vimception extension:#
> https://github.com/ivanov/ipython-vimception
> 
> 
> 
> Thomas
> 
> 
> 
> On 24 April 2015 at 04:21, David Froger <david.froger.ml at mailoo.org>
> wrote:
> 
>         This fix the error:
>         
>         require([
>             'base/js/namespace',
>             'base/js/events',
>             'components/codemirror/keymap/vim'
>           ], function(IPython, events) {
>           events.on('app_initialized.NotebookApp', function() {
>             IPython.CodeCell.options_default.cm_config["keyMap"] =
>         "vim"
>           });
>         });
>         
>         I'm now trying to understand how to switch beetween Vim modes.
>         
>         
>         Quoting David Froger (2015-04-24 13:11:58)
>         
>         > Hi,
>         >
>         > I'm trying to configure ipython-notebook 3.1 (installed with
>         miniconda) to use
>         > CodeMirror Vim keymaps.
>         >
>         > I put in my
>         ~/.ipython/profile_default/static/custom/custom.js:
>         >
>         >     require(['base/js/namespace', 'base/js/events'],
>         function(IPython, events) {
>         >       events.on('app_initialized.NotebookApp', function() {
>         >
>          $.getScript('/static/components/codemirror/keymap/vim.js');
>         >         IPython.CodeCell.options_default.cm_config["keyMap"]
>         = "vim"
>         >       });
>         >     });
>         >
>         > But I got the error when openening a notebook:
>         >
>         >     TypeError: next is undefined (codemirror.js:4622)
>         >
>         > What is the correct way to get CodeMirror Vim Keymaps in
>         ipython-notebook 3.1?
>         >
>         > Thanks,
>         > David
>         >
>         _______________________________________________
>         IPython-dev mailing list
>         IPython-dev at scipy.org
>         http://mail.scipy.org/mailman/listinfo/ipython-dev
>         
> 
> 
> 
> 
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20150424/36d31061/attachment.html>


More information about the IPython-dev mailing list