emacs-devel
[Top][All Lists]
Advanced

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

Re: Clarification about auto-revert-mode and inotify


From: Dima Kogan
Subject: Re: Clarification about auto-revert-mode and inotify
Date: Tue, 21 Oct 2014 11:59:00 -0700

Eli Zaretskii <address@hidden> writes:

>> From: Dima Kogan <address@hidden>
>> 
>> > Indeed, IIUC the current auto-revert-mode implementation only uses the
>> > file-notification code to reduce the amount of polling, but the revert
>> > itself is still only performed from the 5s timer.
>> 
>> I'm attaching a prototype patch to fix this.
>
> I'm sorry, but I still don't understand what's wrong with customizing
> auto-revert-interval.  It seems to allow what you want, and also what
> others might want.  So where's the problem that requires another time,
> and the rest of the complexity you are suggesting?

The issue I'm trying to solve is that there's a delay between when a
file is modified and when auto-revert-mode kicks in. Compare the
user-observable behavior of running 'tail -f file' in a shell, and doing
the supposed equivalent of auto-revert-tail-mode in emacs: with 'tail
-f' the users sees updates instantly, but with auto-revert-tail-mode
they do not.

Before emacs knew about things like inotify, getting this parity would
require rapid polling by emacs, but now we can do this efficiently.
Emacs already does 99% of this, the attached patch just does the last
little bit.



reply via email to

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