diff options
| author | Martin Fischer <martin@push-f.com> | 2026-10-26 09:53:34 +0100 |
|---|---|---|
| committer | Martin Fischer <martin@push-f.com> | 2026-10-31 08:43:09 +0100 |
| commit | 86c74b15fb2bc42aef41ae7651bd97a2afea1c53 (patch) | |
| tree | 20d6580dbf4caf318ea48fb11b07b617463ad67c /user/ideavim | |
| parent | a4a6624d8c8ea86582f3f963f4100435c2ada64d (diff) | |
tweak(user): remap vi navigation for Colemak-DH
Oof, this feels good. Should've done this sooner.
Diffstat (limited to 'user/ideavim')
| -rw-r--r-- | user/ideavim/ideavimrc | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/user/ideavim/ideavimrc b/user/ideavim/ideavimrc index 81dc523..fed7bc9 100644 --- a/user/ideavim/ideavimrc +++ b/user/ideavim/ideavimrc @@ -1,4 +1,45 @@ set clipboard+=unnamed +" Put Vim's directional keys on the Colemak-DH home-row positions. +noremap k h +noremap K H +noremap n j +noremap N J +noremap e k +noremap E K +noremap i l +noremap I L + +" Move the displaced commands onto the old directional keys. Use `o` for +" insert/inner text objects and `l` for open-line/switch-selection-end. +noremap h e +noremap H E +noremap o i +noremap O I +noremap l o +noremap L O + +" Navigate search results. +noremap <Space> n +noremap <BS> N + +" Remap g-prefixed commands. +noremap gn gj +noremap ge gk +noremap g<Space> gn +noremap g<BS> gN +noremap gh ge +noremap gk gh + +" Focus a window in the given direction. +noremap <C-w>k <C-w>h +noremap <C-w><C-k> <C-w>h +noremap <C-w>n <C-w>j +noremap <C-w><C-n> <C-w>j +noremap <C-w>e <C-w>k +noremap <C-w><C-e> <C-w>k +noremap <C-w>i <C-w>l +noremap <C-w><C-i> <C-w>l + " Disable annoying bell sound. Note that visual bell isn't implemented so nothing will be heard or seen. set visualbell |
