I'm running emacs and was wondering if there's a variable which indicates
whether or not a buffer has been modified. I'd like to use this to run
a lisp function upon exiting emacs only if the file's been modified.
Thanks,
Mike Bongiovi
Hi Mike!
Try the function buffer-modified-p.
Greetings,
Hans
Mike Bongiovi (········@neuraltech.com) wrote:
> I'm running emacs and was wondering if there's a variable which indicates
> whether or not a buffer has been modified. I'd like to use this to run
> a lisp function upon exiting emacs only if the file's been modified.
> Thanks,
> Mike Bongiovi
--
------------------------------------------------
| Hans Kratz ** ····@iss.mach.uni-karlsruhe.de |
| -------------------------------------------- |
| SysAdmin |
| Institut fuer Stroemungslehre |
| Universitaet Karlsruhe |
------------------------------------------------
In article <··········@news1.mnsinc.com>, ········@neuraltech.com says...
>
>I'm running emacs and was wondering if there's a variable which indicates
>whether or not a buffer has been modified. I'd like to use this to run
>a lisp function upon exiting emacs only if the file's been modified.
>
>Thanks,
>Mike Bongiovi
>
Answered my own question. In case anyone's interested, the function
buffer-modified-p returns a t if the buffer's been changed since it was last
read in.