How do I jump back to my previous cursor position?
<C-o>
The (Ctrl+o) command jumps the cursor backward through the jump list, returning you to previous cursor positions.
<C-o>
The (Ctrl+o) command jumps the cursor backward through the jump list, returning you to previous cursor positions.
b
The b command moves the cursor backward to the beginning of the previous word.
H
The H command moves the cursor to the first line of the currently visible screen (the "High" position).
guiw
The guiw command converts the entire word under the cursor to lowercase.
{ and }
The { and } commands move the cursor by paragraph — jumping to the previous or next blank line.
yyp
The yyp command duplicates the current line by yanking it and immediately pasting it below.
"ap, edit, "ayy
Vim stores macros in registers, which means you can paste a macro's contents into a buffer, edit it as regular text, and yank it back into the register.
<C-w>=
The = (Ctrl+w then =) command resizes all open split windows so they have equal width and height.
f{char}
The f{char} command moves the cursor forward to the next occurrence of {char} on the current line.
t{char}
The t{char} command moves the cursor forward to the character just before the next occurrence of {char} on the current line.
gg
The gg command moves the cursor to the first line of the file.
G
The G command moves the cursor to the last line of the file.
42G
The 42G command jumps the cursor directly to line 42 in the current file.
g<C-a>
The g command increments numbers across a visual selection so that each subsequent line gets a progressively higher value.
<C-w>c
The c (Ctrl+w then c) command closes the current window without closing the buffer it contains.
daw
The daw command deletes a word including one side of its surrounding whitespace.
dd
The dd command deletes the entire current line, regardless of where the cursor is positioned on that line.
dit
The dit command deletes the text inside the nearest enclosing HTML or XML tag pair without removing the tags themselves.
D
The D command deletes everything from the cursor position to the end of the current line.
de
The de command deletes from the cursor position to the end of the current word.