Saving and Exiting You've seen that you can use the ":q" command to exit, and the ":w" command to save a file. You can combine these commands to save and exit at the same time.
Lesson 7 | Lesson 9
:wq
Or, you can use either one of these commands to save and exit at the same time: :x or SHIFT ZZ If you've edited a file, and try to exit by entering the ":q" command, you'll get an error message. To exit vi without saving the file, enter: :q!
BeginLinux.com(407)-620-4092mike at beginlinux.com