Mailing List Archive

Support open source code!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: tlug: file names that end with ~



>>>>> "Andrew" == Andrew S Howell <andy@example.com> writes:

    Andrew> Although the files are sometimes annoying. I have found it
    Andrew> much more annoying to have wiped out a file by mistake and
    Andrew> not have any backup.

You can run a cron job to clean out really stale ones.  You gotta be
carefule about heuristics for "stale".

    Andrew> Ignore the above, I think the parameter you really want
    Andrew> is:

    Andrew> backup-inhibited's value is nil

If you have a file that you know you don't want backups for that is in 
a format supporting comments (or you don't care about a few extraneous 
editor directives), you can put

/* Local Variables: */
/* backup-inhibited: t */
/* End: */

somewhere after the last formfeed (^L) character, and within 3000
characters of the end of the file.  (The "Local Variables:" is a magic 
string that Emacs uses to determine what the format of the list is.)
See Info | Emacs | File Variables for more information and an
alternative format.

How to default backup-inhibited to `t' and turn it off for precious
files is an exercise left to the reader.  Note that the variable is
"backup-inhibited" rather than the opposite ("backup-enabled")
intentionally, to show that making backups is recommended....

What I do is somewhat different.  If I have a file that I want to keep 
backups of, I check it into my CVS repository.  (RCS and SCCS are
equally good.)  In that case Emacs recognizes that backups are being
kept by a separate subsystem.  It is still convenient to have the *~
files aournd, so I run a cron job to clean them out after 72 hours.

HTH

Steve

--------------------------------------------------------------
Next Nomikai: 15 May Fri, 19:30 Tengu TokyoEkiMae 03-3275-3691
Next TLUG Meeting: 13 June Sat, Tokyo Station Yaesu gate 12:30
Featuring Stone and Turnbull on .rpm and .deb packages
--------------------------------------------------------------
Sponsor: PHT, makers of TurboLinux http://www.pht.co.jp


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links