:vimrc.de
โ† Back to showcase
Vim๐Ÿค– AI-generated

Ergonomics & Speed (keyboard-centric)

For keyboard purists: which-key makes leader mappings discoverable, fast Esc timings, centered cursor on search/scroll and lightweight comfort plugins.

by @vimrc.de ยท โ˜… 60 ยท โฌ‡ 0 copies ยท #keyboard #ergonomics #which-key #speed

X Reddit HN
install curl -L https://vimrc.de/r/ergonomics-speed-keyboard-centric -o ~/.vimrc
vimrc.de/.vimrc
" ============================================================
"  Ergonomics & Speed โ€” keyboard-centric, lightweight plugins
"  which-key for discoverable leader mappings
" ============================================================

call plug#begin('~/.vim/plugged')
Plug 'liuchengxu/vim-which-key'      " shows leader mappings
Plug 'tpope/vim-commentary'
Plug 'tpope/vim-surround'
Plug 'jiangmiao/auto-pairs'
Plug 'machakann/vim-highlightedyank'
call plug#end()

set nocompatible
filetype plugin indent on
syntax enable
set number relativenumber
set hidden mouse=
set ignorecase smartcase incsearch hlsearch
set expandtab tabstop=4 shiftwidth=4
set timeoutlen=400 ttimeoutlen=0
let mapleader = " "

" jk / kj leave insert mode instantly
inoremap jk <Esc>
inoremap kj <Esc>

" Bind which-key to leader
nnoremap <silent> <leader> :WhichKey '<Space>'<CR>

" Common actions
nnoremap <leader>w :write<CR>
nnoremap <leader>q :quit<CR>
nnoremap <leader>h :nohlsearch<CR>
nnoremap <leader>bn :bnext<CR>
nnoremap <leader>bp :bprevious<CR>
nnoremap <leader>bd :bdelete<CR>

" Keep cursor centered on search / scroll
nnoremap n nzzzv
nnoremap N Nzzzv
nnoremap <C-d> <C-d>zz
nnoremap <C-u> <C-u>zz
NORMAL44 linesvim

Comments (0)

No comments yet. Be the first.

Browse more configs on vimrc.de โ†’