Your Question: How Do You Save in Unix?
Contents to Save a File, You Must First Be in Command Mode. Press Esc to Enter Command Mode, and Then Type: Wq to Write and Quit the File. the Other, Quicker...
Contents
To save a file, you must first be in Command mode. Press Esc to enter Command mode, and then type :wq to write and quit the file. The other, quicker option is to use the keyboard shortcut ZZ to write and quit. To the non-vi initiated, write means save, and quit means exit vi.
How do you save a file in Unix?
Be sure to use the save command often when editing an important document.
…
bold.
| :w | save changes (i.e., write) to your file |
|---|---|
| :wq or ZZ | save changes to file and then qui |
| :! cmd | execute a single command (cmd) and return to vi |
| :sh | start up a new UNIX shell – to return to Vi from the shell, type exit or Ctrl-d |
Must Read
How do I save and quit in Linux?
Press the [Esc] key and type Shift + Z Z to save and exit or type Shift+ Z Q to exit without saving the changes made to the file.