A note on ZZ: On most keyboards, it is easy to depress Ctrl instead of Shift. When you're just ready to use ZZ to save and quit, you can sometimes hit Ctrl-Z by mistake.

Under UNIX-like operating systems, this suspends the active process and returns the user to the shell. To us newbies it looks like vi has closed without saving, but ideally, your file can (and should) be recovered before the session is closed.

First, type


Look through the list (it should hopefully be very very small). One of the processes should have the word vi in the last column. The number used to refer to this process is shown in square brackets at the start of the column. For example:

1  + Stopped (user)       vi

In the above example, vi is process 1. Therefore, to retrieve it (along with the needed file) we use

fg 1

Replace 1 with the appropriate number. This should bring vi to the foreground and get it running nicely once more.

I don't know, I'm just a newbie.