Michael Albinus <[email protected]> writes: > Thierry Volpiatto <[email protected]> writes: > >>> Hi, > > Hi Thierry, > > [first of all: ange-ftp is not part of Tramp. Yes but you are the one who know how it works ;-)
> An Emacs mailing list, or filing an Emacs bug, might be more > appropriate. But so what ...] Ok. >>> it seem that `ange-ftp-get-files' always check the content of his cache >>> in hashtable and doesn't update it after first listing. >>> Removing the gethash check to `ange-ftp-files-hashtable' fix it. >> >> So actually when some files have been copied or removed, one should >> reread the ftp directory to update cache. >> >> This should been done automatically isn't it? > > Yes. This not implemented in ange-ftp. > >> I have fixed this in helm by doing this before listing a directory: >> >> --8<---------------cut here---------------start------------->8--- >> ;; Always reread ftp directory, otherwise we will never be aware >> ;; of new or deleted files. >> (when (eq 'ftp (file-remote-p directory 'method)) >> (setq ange-ftp-ls-cache-file nil) >> (remhash directory ange-ftp-files-hashtable)) >> --8<---------------cut here---------------end--------------->8--- > > That's a sledge-hammer approach :-) Yes it is just a work around, it is the only way I found apart modifying ange-ftp itself of course, which would be better. > I will see, whether I could improve ange-ftp for this. Unfortunately, > there are several places one needs to invalidate the cache. Cool, looking forward for your changes. Thanks. -- Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997 _______________________________________________ Tramp-devel mailing list [email protected] https://lists.gnu.org/mailman/listinfo/tramp-devel
