[Top][All Lists]

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

Re: autorevert.el

From: Luc Teirlinck
Subject: Re: autorevert.el
Date: Mon, 22 Mar 2004 13:39:08 -0600 (CST)

Eli Zaretskii wrote:

   I'm at a loss how you arrived at that conclusion, especially since I
   suggested looking at the size for the benefit of systems that cannot
   use the time stamp.  Isn't this better than not knowing the directory
   changed at all?

But the probability of finding it out this way is close to zero.

Stefan Monnier wrote:

   He ment to check it additionally to the mod-time.
   I.e. if either the mod-time or the size has changed, then the dir
   has changed.

Yes, but the size only seems to change after adding or deleting
approximately 200 files.  Many (probably most) of my directories do
not even contain that many files and never will.  They have size 4096
and always will.

What would seem to happen on MS Windows if we did that would be that,
normally, directories do not autorevert, so the user believes that
they never autorevert.  Once in a very blue moon, one huge directory
suddenly starts autoreverting all the time.  The user wonders what is
going on.  All of a sudden it stops autoreverting and never
autoreverts again.  Note that this system is very much biased toward
autoreverting large directories.  Small directories, that would be
very cheap to autorevert, never will be autoreverted.  It would seem
to be relatively better never to autorevert.  Or automatically revert
directories whose size is _below_ a certain threshold every
auto-revert-interval seconds, on systems for which we have no better

Note that to check whether the size has changed, dired needs to store
the old size.  I did not check whether it currently does that.

What if I just go ahead and install my patches to autorevert and
dired?  (Additional changes can always be made later.)  Then maybe
somebody volunteers to solve the portability problem in the only
really correct way.  The problem affects dired proper and ido-mode as
much as it affects auto-revert.  Do the maintainers of the various
ports routinely read emacs-devel?  None appear to be Cc-ed.

Otherwise people using non-POSIX systems can try to set
buffer-stale-function to various values in dired-mode using
dired-mode-hook and see what works best.



reply via email to

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