Pressing any other key will save the buffer. If you only have one buffer active this will also terminate Ved.
Selecting the ``Close'' option from the ``File'' menu is identical to [Esc][Q].
When Ved saves your file a check is done to see if another user or process has modified the file while you were editing. If this is the case, you will receive a prompt advising that the file has been modified. Respond accordingly. Note that this check compares the modification field of the files inode.
To be extra safe, Ved will create backups of your modified files before saving. This is controlled in the RC file with the following options:
Example: If you have dobackups set to ``true'', backup_suffix to ``~'' and backup_prefix to ``.'' and edit the file ``foo'' you will end up with a copy of the original ``foo'' named ``.foo~'' and a new, modified ``foo''. The backup process will destroy old backups as new ones are created.
On our system we have the following settings:
Option Dobackups TRUE
Option Backup_suffix "~"
Option Backup_prefix "~/.ved_backups/"
This creates backups in the hidden directory ``.backups'' in the user's home directory. It is up to the user to create the backup directory--Ved will not create backup directories.
If Ved notices that there is a ``/'' in the Backup_Prefix , only the filename portion of the filename will be used. Again, using the above settings, if we were to edit the file docs/tex/ved.tex, the backup would be /.ved_backups/ved.tex. Caution: this does mean that files with the same name in different directories will overwrite themselves in the backup directory.
Another backup strategy would be to use a Backup_Prefix like ``.backups/''. Now, you will have to create backup sub-directories in all the directories you edit files in. However, this does avoid littering your hard drive with backups of every file you edit. If the directory does not exist, it will not be created; however, you will receive a warning message that the backup could not be created.