The VI Editor
VI is a standard text editor found on LINUX/UNIX systems. With VI you can create new files or edit existing files. To start VI you should type vi filename where filename is the name of a new or existing file which you wish to edit. Use the arrow keys to scroll through the document. The following is a list of the commands which are used in VI to edit documents. For a more complete description of the use of the VI editor, check out the section concerning VI in the LINUX Users' Guide written by Larry Greenfield
This is a partial list of the common VI command. To enter one of these command, press the ESC key then the command key which is listed below:
| COMMAND | What it does |
| a | appends text after the cursor |
| A | appends text at end of the line |
| b | back up to beginning of word in current line |
| d | delete line |
| e | move to end of word |
| G | go to end of file |
| h | move the cursor to the left |
| H | move the cursor to the top of the screen |
| i | insert text before the cursor |
| I | insert text at beginning of line |
| j | move the cursor down |
| k | move the cursor up |
| l | move the cursor to the right |
| o | open a line below the current line |
| O | open a line above the current line |
| r | replace character at cursor with the next character typed |
| u | undo the last change made |
| U | restore current line, discarding changes |
| w | move to begining of next word |
| x | delete character at cursor |
| X | delete character before cursor |
| y | Yank (or coy) operator |
| Y | make copy of current line |
| $ | go to end of line |
| :q! | quit VI without saving changes |
| :wq | write changes to file then quit VI |