From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Albinus Subject: Re: [Patch] org-display-inline-images: Add support for remote images Date: Tue, 25 Nov 2014 18:04:49 +0100 Message-ID: <8761e31aa6.fsf@gmx.de> References: <87vbm3of2o.fsf@selenimh.mobile.lan> <87bnnv1e95.fsf@gmx.de> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48410) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XtJXv-0004YS-Vc for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 12:05:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XtJXp-0000Ve-Oh for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 12:04:59 -0500 Received: from mout.gmx.net ([212.227.15.19]:63824) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XtJXp-0000VY-E7 for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 12:04:53 -0500 In-Reply-To: (Kit-Yan Choi's message of "Tue, 25 Nov 2014 10:45:50 -0500") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Kit-Yan Choi Cc: emacs-orgmode@gnu.org Kit-Yan Choi writes: > Michael, Hi Kit, > Thanks for the suggestion. Indeed `file-local-copy' would have made > the code cleaner. Yet `file-local-copy' generates a new filename each > time it's run. But I wanted to allow the code to check whether the > remote image has already been fetched before and so skip unnecessary > file transfer, which takes time (think of it like "rsync -a"). > Therefore I wanted to preserve the remote path under a temporary > directory. After first retrieval via file-local-copy, you could cache this information somewhere for later use. Or you could write a ticket towards Tramp, that file-local-copy shall remember that a file was downloaded already, and should offer that file for reuse. Note: I'm the Tramp maintainer :-) > Best, > Kit Best regards, Michael.