Go to the first, previous, next, last section, table of contents.


Controlling Auto-Saves

For the documentation of the variables controlling the making of auto-save files see section Auto-Saving Files.

Function: make-auto-save-name file-name
Returns a string naming the file which should hold the auto-saved version of the file file-name.

(make-auto-save-name "/tmp/foo")
    => "/tmp/#foo#"

Function: auto-save-function buffer
This function is called automatically whenever a buffer (buffer) needs to be auto-saved.

It firstly tries to use the auto-save-hook hook to auto-save the file, if this fails (i.e. the hook returns nil) it is done manually (using the write-buffer function).

Hook: auto-save-hook
Called by auto-save-function (with the buffer as an argument) when a buffer is to be auto-saved.

Command: delete-auto-save-file &optional buffer
This command deletes the auto-saved version of the buffer, if one exists.

Function: auto-save-file-newer-p file-name
This function returns t when there is an auto-saved version of the file called file-name which is newer than file-name.

Command: recover-file &optional buffer
If an auto-saved version of the buffer exists it is read into the buffer, overwriting its current contents. If any changes to the buffer will be lost the user is asked for confirmation.


Go to the first, previous, next, last section, table of contents.