View file File name : jed008.html Content :<!DOCTYPE html> <html lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"> <meta name="generator" content="hevea 2.35"> <link rel="stylesheet" type="text/css" href="jed.css"> <title>Backup and Auto-save Files</title> </head> <body > <a href="jed007.html"><img src="previous_motif.svg" alt="Previous"></a> <a href="index.html"><img src="contents_motif.svg" alt="Up"></a> <a href="jed009.html"><img src="next_motif.svg" alt="Next"></a> <hr> <h2 id="sec11" class="section">7 Backup and Auto-save Files</h2> <p>On UNIX and MS-DOS systems, <span style="font-weight:bold">jed</span> creates backup files by appending a <code class="verb">~</code> character to the filename. The VMS operating system handles backup files itself. <span style="font-weight:bold">jed</span> periodically auto-saves its buffers. On UNIX and MS-DOS, auto-save files are prefixed with the pound sign <span style="font-family:monospace">#</span>. On VMS, they are prefixed with <code class="verb">_$</code>. The auto-save interval may be changed by setting the variable <code class="verb">MAX_HITS</code> to the desired value. The default is 300 “hits” on the buffer. A “hit” is defined as a key which MAY change the state of the buffer. Cursor movement keys do not cause hits on the buffer.</p><p>Like many of <span style="font-weight:bold">jed</span>’s features, the names of auto-save and backup files can be controlled by the user. The file <code class="verb">site.sl</code> defines two functions, <code class="verb">make_backup_filename</code>, and <code class="verb">make_autosave_filename</code> that generate the file names described in the previous paragraph. Like all S–Lang functions, these functions may be overloaded and replaced with different ones. See also information about <code class="verb">find_file_hook</code> in the section on hooks.</p><p>On UNIX systems, <span style="font-weight:bold">jed</span> catches most signals and tries to auto-save its buffers in the event of a crash or if the user accidently disconnects from the system (<span style="font-family:monospace">SIGHUP</span>).</p><p>If an auto-save file exists and you is desire to recover data from the auto-save file, use the function <code class="verb">recover_file</code>. Whenever <span style="font-weight:bold">jed</span> finds a file, it checks to see if an auto-save file exists as well as the file’s date. If the dates are such that the auto-save file is more recent <span style="font-weight:bold">jed</span> will display a message in the mini-buffer alerting the user of this fact and that the function <code class="verb">recover_file</code> should be considered.</p> <hr> <a href="jed007.html"><img src="previous_motif.svg" alt="Previous"></a> <a href="index.html"><img src="contents_motif.svg" alt="Up"></a> <a href="jed009.html"><img src="next_motif.svg" alt="Next"></a> </body> </html>