นี่คือสูตรโกงสำหรับ VIM
โกงแผ่นสำหรับเสียงเรียกเข้า
To quit the vi editor without saving any changes you've made:
If you are currently in insert or append mode, press Esc.
Press : (colon). The cursor should reappear at the lower left corner of the screen beside a colon prompt.
Enter the following:
q!
This will quit the editor, and all changes you have made to the document will be lost.
บางอย่างเพิ่มเติม ::
การปิดและการบันทึกไฟล์
When you edit a file in vi, you are actually editing a copy of the file rather than the original. The following sections describe methods you might use when closing a file, quitting vi, or both.
Quitting and Saving a File
The command ZZ (notice that it is in uppercase) will allow you to quit vi and save the edits made to a file. You will then return to a Unix prompt. Note that you can also use the following commands:
:w to save your file but not quit vi (this is good to do periodically in
case of machine crash!).
:q to quit if you haven't made any edits.
:wq to quit and save edits (basically the same as ZZ).
Quitting without Saving Edits
Sometimes, when you create a mess (when you first start using vi this is easy to do!) you may wish to erase all edits made to the file and either start over or quit. To do this, you can choose from the following two commands:
:e! reads the original file back in so that you can start over.
:q! wipes out all edits and allows you to exit from vi.