emacs-devel
[Top][All Lists]
Advanced

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

Re: [Emacs-diffs] trunk r115439: * autorevert.el (auto-revert-notify-add


From: Stefan Monnier
Subject: Re: [Emacs-diffs] trunk r115439: * autorevert.el (auto-revert-notify-add-watch): Do not handle symlinked files.
Date: Tue, 10 Dec 2013 23:36:01 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

>> >> I think this patch is acceptable, but if/when we try to write a generic
>> >> file-watcher Elisp API, it would be good to make this work (probably by
>> >> adding a watcher on the symlink's target).
>> > It's up to the user to say whether she wants to watch the symlink or
>> > its target, I think.

autorevert cares about keeping the buffer in sync with the contents of
the file available at buffer-file-name.  So the user has already said
what she wants.

This need could occur in other circumstances as well: inotify and
friends usually work at a "shallow" level whereas many uses of
file-tracking care about the contents (hence following any indirections
like symlinks as deeply as needed).  So a good "notification" Elisp API
should probably provide the feature.

>> In general I agree. But Stefan was commenting on my change in
>> autorevert.el. Here it is obvious, that the target shall be watched.
>> I believe.
> What if the target is a directory?

I don't understand your question: whether the target is a directory or
not doesn't seem to make any difference.


        Stefan



reply via email to

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