VI Modes and Commands Flashcards
some Visual Editor commands and 2 modes page 78-79
command mode
Characters typed perform actions like moving the cursor, cutting or copying text, or searching for a particular text string. vi opens in command mode.
insert mode
Actual text is typed or overwritten.
i
Insert before cursor (insertion command)
a
Append after cursor (insertion command)
o (little)
Insert below current line (insertion command)
O (big)
Insert above current line (insertion command)
yy
Copy line into memory (yank-yank) (insertion command)
p
Works with yy to place copied line onto the existing or next line (insertion command)
5p
Places five lines of what was copied, at cursor (insertion command)
x
Delete current character (deletion command)
r
Replace current character (deletion command)
dd
Delete current line (deletion command)
h
Move cursor one place to the left (Navigation Commands)
l (lowercase L)
Move cursor one place to the right (Navigation Commands)
j
Move cursor one place down (Navigation Commands)