Skip to content

Instantly share code, notes, and snippets.

@aneurysmjs
Created June 9, 2024 21:11
Show Gist options
  • Save aneurysmjs/28caa31dcf9cd473d7aa3bf1520168cd to your computer and use it in GitHub Desktop.
Save aneurysmjs/28caa31dcf9cd473d7aa3bf1520168cd to your computer and use it in GitHub Desktop.
vim motions

NORMAL mode

navigation

h left
j down
k up
l right

these commands can be prefixed with a number:
5l will move 5 times to the right
3j will move 5 times down
... and so on

w go forward word by word
b go backward word by word
e jump to the end of a word

these commands can be prefixed with a number:
5w move 5 words forward ... and so on

$ jump to the end of line
0 jump to the beggining of the line
^ jump the first non-empty character on the line
f+the char where we want to jump jump to the next specific character on the line F+the char where we want to jump jump to the previous specific character on the line

vertical navigation

) move by one sentence down
( move by one sentence up

} move by one paragraph down
{ move by one paragraph up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment