vi [filename]
CURSOR DISPLACEMENT
[n] l hjk cursor movements
^ D move the cursor 12 lines down
^ U move the cursor in the top 12 lines
^ F cursor forward one page
^ B cursor back one page
G cursor at the end of the text
[n] G cursor to line n
| Cursor to first character of the line
[n] | n character at the cursor line
^ G shows the penultimate row of the information
H Cursor to first line of the screen
[n] H n cursor to the line of the screen
M cursor to center screen
L cursor to the line of the screen
[n] L n cursor to last line of the screen
[n] w cursor to next word
W as w but does not take account of punctuation
[n] b cursor to previous word
B as b but does not take account of punctuation
and cursor at the end of the word where you are
^ Cursor to first non-white
D cursor at the start line?
O cursor at the start line?
$ Cursor at the end of line
SEARCH
(pattern) search text
/ [pattern] tpattern look for the forward
[pattern] find the pattern behind
n repeat search forward
N repeat search backward
/ [pattern] / n cursor n lines after the pattern
pattern metacharacters
^ Beginning of line
$ At the end of the line
. Any character
[] Enclosing characters
f [a] search in the current row forward
F [a] find the current row in the back
INSERTION
i insert text left of cursor
to insert text to the right of the cursor
To insert at the end of the line
U ^ back to insert a word in
@ Insert back in the cio 'che e' was added
or placement on a line below
O insertion on a line above
Esc end entering
CORRECTIONS
[n] x delete a character
r [a] replaces the original character with another
R replaces all characters up to <ESC> data
[n] s replaces a character with a string
dw deletes a word before the cursor
db deletes a word behind the cursor
dd delete a line
D delete this' which is under the cursor
cw replace a word
cf [character] changes the current line to (a) included
ct [character] as an exception cf
cc allows you to change a line
dL erases all the lines of the screen under the cursor
DG erase the line where the cursor is at the end of file
df [character] clears the current line from cursor to the character including
dt [character] as df, is excluded
REMEDY FOR RRORI
u undo
U undo Line
UNION OF LINES
[n] J put the line below at the bottom of the current
DUPLICATION OF LINES
[n] Y charging into a buffer, the current line
p recopy the lines contained in the buffer
retrieves the last cancellation
MANIPULATION OF FILES
: w saves, continues
: w <name> save with new name, continues
: x, yw <name> writes lines from x to y on the file <name>
: wq save and quit
ZZ saves and exits
q leave unless changes were made
: q! abandons
: e <name> enter into the editor view <name>
: r <name> inserted in the text <name> end in line under the cursor
BOOKMARK
m <carattere> create bookmark
'<carattere> va a bookmark
VIDEO MANAGEMENT
^ L redraws video
z <return> puts the current line to the screen
z. current line in the middle of the screen
z-line acorrente at the end of the screen



































