2

On vim's help :help jumplist I can read:

Jumps are remembered in a jump list. With the CTRL-O and CTRL-I command you can go to cursor positions before older jumps, and back again. Thus you can move up and down the list.

However, on my terminal mintty, Vim makes no differences between Tab and Ctrl+i.

I am wondering what is the magic to use Ctrl+i on Vim?

nowox
  • 459
  • 4
  • 14

2 Answers2

8

ControlI is Tab (I is character code 73 and control subtracts 64; this leaves us with 9, which is TAB).

Every vim install I've tried this on (including gvim) maps this to <tab> - even :help <ctrl-i> shows us that the feature you want is actually also bound to <tab>.

From my testing, it works fine on any vim install that doesn't map <tab> to anything else. Use :map <tab> to check if you've got any mappings set up for that key.

Wolfie
  • 667
  • 3
  • 8
1

I'm not sure if this is doable in mintty, but I have a workaround for iTerm on Mac OS and the same would work for alacritty which is cross platform.

In vim I have this mapping

nnoremap <C-n>i <C-i>

In teminal preferences I have set up ^i to send hex codes "0xe 0x69" to the shell.

For alacritty you need to add this to the key mapping section of your alacritty.xml

- { key: I,        mods: Control, chars:  "\x0e\x69"                       }
niko
  • 11
  • 1