Originally posted by amer_58
With the vi I can only view the file, I need to edit it as well.
No. This is why we are telling you that vi is not newbie friendly. To insert something before the letter the pointer is placed type the letter i
nsert). Then you enter in insertion mode and you can write. After you write you press Esc
to leave insertion mode. The letter a
ppend) will append something. You will enter in insertion mode and what you type will be added after the cursors position. Again press Esc to leave insertion mode. x
is for deleting the letter under the cursor. v
is for entering visual mode. To highlight something, what you do in windows editors by pressing shift and the arrows, or by using the mouse if you want to copy a sequence of letters. Then with d
you cut the highlighted part, with y
you copy the highlighted part, with p
you past it. r
is for replacing, dd
is for deleting an entire line, :q
is for quitting, :q!
is for quiting without saving, ZZ
is for save and quit :open
is for opening files :new
is for opening a empty new file. if you type :765
the cursor will move to line 765. There are really a lot more commands and features (for advanced searching, for highlighting a source code). Those are just the basics... If you learn to use vi you'll love it, but it's pretty frustrating in the beginning.