Previous topic |
Next topic |
Contents |
Contact z/OS |
Library |
PDF
Basic principles z/OS UNIX System Services User's Guide SA23-2279-00 |
|
To begin using vi, you type the command:
where filename is the name of a file you want
to edit. This can be an existing file, or it can be a new file that
you want to create.The vi command begins a vi session. In a vi session, you enter input that creates or changes the contents of the file specified on the command line. vi reads and uses the input you type until you quit your vi session. In a vi session, you are always in one of two modes:
To switch from Insert Mode to Command Mode, simply press the key marked <Esc>. If you are not sure which mode you are in, press <Esc> several times. This always brings you back to Command Mode. To delete a character, you must be in Insert Mode. Pressing <Backspace> deletes the last character you typed; pressing <Backspace> twice deletes the last two characters, and so on. vi usually does not immediately delete these characters on the screen—it just backs up the cursor so that anything you enter is typed over the characters that were there. When you leave Insert Mode, vi adjusts the screen to remove any characters that were deleted by <Backspace> and not over-typed. To quit a vi session, do one of these:
|
Copyright IBM Corporation 1990, 2014
|