commands Flashcards
move left
h
move up
k
move down
j
move right
l
quit and save
:wq
delete character under cursor
x
insert text at cursor
i
insert append at end of line
A
capital a
undo last
u
delete from cursor to end of line
d$
goto beginning of the line to first non-blank char
shift 6
goto absolute beginning of line
0
delete from cursor to end of the word
the cursor must be on the first letter of the word to delete the entire word
de
delete to end of the current word
delete operator
d
delete from the cursor to the start character of the next word, not including the start character
dw
what do numbers before a motion command or operator mean, ie 3w
how many times the motion repeats
3w is 3 words forward
2w
the exact location of the cursor
first character 2 words ahead
e
cursor at end of each word ahead
p
put paste clipboard after the cursor
P
put paste before the cursor
d2w
delete 2 words from the cursor to the start of third-word character not including the third word character
delete entire line and put in register
dd
delete cut 2 lines
2dd
undo the last command
u
fix undo the whole line
U
replace one character without going into insert mode
r then the letter
change letters from the cursor to end of word
ce - this will put you also into insert
change from the cursor to the end of the line
c$
Retrace your movements in file in backwards.
ctrl o
Retrace your movements in file in forward
ctrl i
change from the cursor to end of 3rd word
c3e
move to the bottom of the file
G
move to the start of the file
gg
go to a specific line in the document
line number G
399G
Search and replace word(s)/errr
/
/search enter
move the screen to the top middle and bottom relative to the cursor. the cursor stays put on the same line number
zt, zz, zb
visual block mode select and insert
ctrl-v I
visual block mode select and change
all commits to squash
ctrl-v c
visual block mode select and delete
ctrl-v d
visual block select to end of each line
ctrl-v $ j