help-gnu-emacs
[Top][All Lists]
Advanced

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

Reliable indication that auto-saving should not be done


From: Denis Bueno
Subject: Reliable indication that auto-saving should not be done
Date: Thu, 29 Mar 2007 20:10:47 -0400

All-

I wrote a pretty simple function that saves the current buffer to a
file in a local darcs repo and records its changes. I wanted versioned
records of changes I make to the files I edit.

I install that function in `auto-save-hook'. However, in some buffers
auto-saving is off (for security reasons) but my hook still gets run.
My questions are, first of all, should the auto-save hook be run when
auto-saving is off? Secondly, if so, what is a reliable indication
that auto-save is on (or off)?

(In particular when I open encrypted files using crypt++.el, it sends
a message to the minibuffer, saying "Auto save off (in this buffer)"
and my hook is run just the same.)

Thanks in advance.

-Denis




reply via email to

[Prev in Thread] Current Thread [Next in Thread]