17
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

vimのINSERTモードでカーソル上下左右移動できるようにする

Last updated at Posted at 2017-09-05

「数文字だけ移動したい、でもINSERTモードを抜けるのは面倒!」というとき、INSERTモードでもカーソルの上下左右移動をできるようにする方法です。部分的にEmacsキーバインドを採用するやりかたです。

やりかた

.vimrcに次のキーマップ定義を追加しておきます。

.vimrc
imap <C-p> <Up>
imap <C-n> <Down>
imap <C-b> <Left>
imap <C-f> <Right>

以上。

17
10
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
17
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?