Setting via vimrc does not seem to be reflected inside of VIM

47 Views Asked by At

I have the following vimrc:

if empty(glob('~/.vim/autoload/plug.vim'))
    silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs
        \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
    autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif
call plug#begin('~/.vim/plugged')
Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets'
call plug#end()

let g:UltiSnipsExpandTrigger = '<C-j>'
let g:UltiSnipsJumpForwardTrigger = '<C-j>'
let g:UltiSnipsJumpBackwardTrigger = '<C-k>'

The settings of <C-j> for expansion and jumping forward and <C-k> for backward jump is consistent with official documentation https://github.com/SirVer/ultisnips/blob/master/doc/UltiSnips.txt

When the above vimrc is sourced from within a file, while the output of :verbose map <C-j> reveals that the settings has been read in from the vimrc.

The output of :verbose map <C-k>, however, is No mapping found.

This is confusing--why would only <C-j> be recorded but not <C-k>?

:echo g:UltiSnipsJumpForwardTrigger provides output <C-j>, and,

:echo g:UltiSnipsJumpBackwardTrigger provides output <C-k> indicating that these settings were read in from the vimrc and yet :verbose map <C-k> does not provide expected output. Animated gif of the various tests provided here: https://i.stack.imgur.com/vW747.jpg and reproduced below.

enter image description here

0

There are 0 best solutions below