Skip to content

Shortcuts

Raphael edited this page Apr 30, 2020 · 4 revisions

Shorcuts

Normal

KeyMap Mode Description
j N accelerated-jk
k N accelerated-jk
K N Show document
Y N Yank to end
TAB N V SelectionRange need language server support
g + a N V vim-easy-align usage
g + d N Jump to definition
g + y N Jump type definition
g + r N Show references
] + b N Prev buffer
[ + b N Next buffer
] + e N Prev diagnostic
[ + e N Next diagnostic
] + g N Prev git chunkinfo
[ + g N Next git chunkinfo
Ctrl + f N Scroll on float window
Ctrl + b N Scroll on float window
Ctrl + s N Save buffer
Ctrl + x N Close buffer
Ctrl+x + Ctrl+f N Open file filter like emacs ivy (cousnel-find-file)

Insert Key like emacs

KeyMap Mode Description
Ctrl + w I delete word
Ctrl + h I backspace
Ctrl + d I delete
Ctrl + k I delete line
Ctrl + u I delete to the line first
Ctrl + b I left
Ctrl + f I right
Ctrl + a I move to the first char
Ctrl + e I move to the end
Ctrl + s I Save buffer
Ctrl + q I Save buffer and quiet
Ctrl + o I jump to new line

Smooth scroll

KeyMap Mode Description
Ctrl + f N Scroll forwards
Ctrl + b N Scroll downwards
Ctrl + u N Scroll upwards
Ctrl + d N Scroll downwards

Comment

KeyMap Mode Description
gc N V caw.vim
gcc N V caw.vim

vim-sandwich

KeyMap Mode Description
sa N V vim-sandwich
sd N V vim-sandwich
sr N V vim-sandwich
srb N V vim-sandwich

Easymotion

KeyMap Mode Description
gs + j N Easymotion w
gs + k N Easymotion b

Choose win

KeyMap Mode Description
- N Choosewin
Leader + - N ChooseWinSwapStay

Mulitple edit by coc.nvim

KeyMap Mode Description
Alt + s N Cursors position
Alt + d N Select current word
Alt + c V Cursors range

dsf.vim

KeyMap Mode Description
dsf N dsf.vim
csf N dsf.vim

splitjoin.vim

KeyMap Mode Description
sj N splitjoin.vim
sk N splitjoin.vim

vim-expand-region

KeyMap Mode Description
v v vim-expand-region
V V vim-expand-region
Key Mode Action
j or k 𝐍 Move up and down the tree
l or Return 𝐍 Toggle collapse/expand directory or open file
h 𝐍 Collapse directory tree
t 𝐍 Expand directory tree recursively
. 𝐍 Toggle hidden files
Space 𝐍 Select entry
* 𝐍 Invert selection (select all)
& or </kbd> 𝐍 Change into current working directory
~ 𝐍 Change to user home directory
u or Backspace 𝐍 Change into parent directory
u 2/3/4 𝐍 Change into parent directory count
st 𝐍 Open file in new tab
sv 𝐍 Open file in a horizontal split
sg 𝐍 Open file in a vertical split
N 𝐍 Create new directories and/or files
K 𝐍 Create new directory
c / m / p 𝐍 Copy, move, and paste
r 𝐍 Rename file or directory
dd 𝐍 Trash selected files and directories
y 𝐍 Yank path to clipboard
w 𝐍 Toggle window size
]g 𝐍 Next dirty git item
[g 𝐍 Previous dirty git item
x or gx 𝐍 Execute associated system application
gd 𝐍 Open git diff on selected file
gl 𝐍 Open terminal file explorer with tmux

Leader

KeyMap Mode Description
Leader + ; N Manage List extensions
Leader + , N Coc commands
Leader + TAB N Switch to last buffer
Leader + ' N CocList resume

Buffer

KeyMap Mode Description
Leader + bc N Keep only current buffer
Leader + bb N Show buffer list
Leader + bx N Delete all buffers

Code

KeyMap Mode Description
Leader + ca N V Lsp code action
Leader + cd N Lsp show document
Leader + ce N Lsp show all diagnostics
Leader + cf N V Lsp format
Leader + cF N Lsp autofix problem current line
Leader + ci N Lsp find implementation
Leader + cn N Default action for next item
Leader + cp N Default action for prev item
Leader + cj N V Show definition and references
Leader + cr N Lsp rename
Leader + cs N Search workspace symbols
Leader + cR N Quick Run
Leader + cw N Remove space at the end of lines

File

KeyMap Mode Description
Leader + e N Open defx file tree
Leader + j N Open coc-explorer file tree

Debug Only appear and use on Go file

KeyMap Mode Description
Leader + da N Toggle Breakpoint
Leader + db N Toggle Trace point
Leader + dc N Clear all points
Leader + dd N Debug
Leader + dt N Dlv Test
Leader + dr N DlvRemoveBreakpoint
Leader + dR N DlvToggleTracepoint

Find

KeyMap Mode Description
Leader + fa N Find input char
Leader + ff N Find file
Leader + fh N Find history file
Leader + fl N Find locallist
Leader + fg N Find file with git
Leader + fw N Find current word
Leader + fW N Find window
Leader + fu N Find git diff files
Leader + fv N Find visual select

Outline vista.vim

KeyMap Mode Description
Leader + i N Open outline

Mundo

KeyMap Mode Description
Leader + m N Mundo tree toggle

Writing Goyo.vim

KeyMap Mode Description
Leader + G N Goyo

Version control

KeyMap Mode Description
Leader + ga N Git add
Leader + gb N Git diff split
Leader + gc N Git commit
Leader + gd N Git blame
Leader + gf N Git fetch
Leader + gg N Git status
Leader + gp N Git push
Leader + gs N Git status
Leader + gl N Gina log

Open

KeyMap Mode Description
Leader + oc N Open personal zshrc tmux conf
Leader + os N Open startify dashboard
Leader + om N Open markdown preview
Leader + ot N Open terminal

PackageManage

KeyMap Mode Description
Leader + pu N Update the all plugins
Leader + pu N Clean up the runtime cache
Leader + pu N Get the update log

Quiet

KeyMap Mode Description
Leader + qq N Save and quiet
Leader + qw N Quiet without save

Repl

KeyMap Mode Description
Leader + rr N Open Repl
Leader + rq N Quick Repl
Leader + rl N V Send line to repl
Leader + rp N repeat command
Leader + rc N Clear
Leader + r+CR N
Leader + r+ESC N

Quiet

KeyMap Mode Description
Leader + ss N Save session
Leader + sl N Load session

Toggle

KeyMap Mode Description
Leader + ti N Toggle IndentLine
Leader + tc N Toggle colorscheme
Leader + tn N Toggle number
Leader + ts N Toggle spell check

Window

KeyMap Mode Description
Leader + s N horizontally split
Leader + v N vertical split
Leader + h N jump left window
Leader + j N jump bottom window
Leader + k N jump top window
Leader + l N jump right window
Leader + H N move window to left
Leader + J N move window to bottom
Leader + K N move window to top
Leader + L N move window to right
Leader + x N swap window
Leader + c N close window
Leader + o N close other window
Leader + R N spin window