Skip to content

Instantly share code, notes, and snippets.

@hamidreza-s
Last active August 11, 2017 14:15
Show Gist options
  • Save hamidreza-s/10571281 to your computer and use it in GitHub Desktop.
Save hamidreza-s/10571281 to your computer and use it in GitHub Desktop.
Vim cheat sheet
# in command mode
Ctrl+E (move screen up)
Ctrl+Y (move screen down)
H (move cursor to head of screen)
M (move cursor to middle of screen)
L (move cursor to end of screen)
gg (move cursor to head of file)
G (move cursor to end of file)
# example
gg -> yG (yank whole file's text to vim clipboard)
gg -> "+yG (yank whole file's text to OS clipboard)
gg -> dG (delete whole file's text)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment