emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [PATCH] Persistently save downloaded inline remote images


From: Jack Kamm
Subject: Re: [PATCH] Persistently save downloaded inline remote images
Date: Mon, 07 Dec 2020 07:17:14 -0800

> Jack, as the author of the org-display-remote-inline-images commit, what
> do you think about this patch?

This patch takes the same approach as an earlier attempt by Kit in 2014
[1].  That patch was never merged; Michael objected that the approach
seemed too complex, and suggested using file-local-copy and cacheing the
filename instead; he also suggested implementing this cacheing
functionality in Tramp instead of Org.

So, when I submitted a new attempt at this, I chose to cache by simply
opening the image files in Emacs instead, since the implementation is
much simpler, and would hopefully sidestep the objections from the 2014
approach.

While cacheing via tempfiles is more complex, it does have some
benefits: it allows cacheing across Emacs sessions, and it avoids the
side effect of opening the image files in Emacs.

I'm agnostic whether tempfiles or Emacs buffers are ultimately
better. My inclination is to be conservative and stick with the status
quo unless there's a compelling reason to switch.

So, I suggest Ferdinand confirm he's tested the existing "cache" option,
and articulate why he found it unsuitable, before merging this.

If we do proceed in this direction, I'd suggest replacing the current
cache mechanism entirely -- I don't see a good reason to maintain 2
solutions to the same problem. Also, we could combine the "download" and
"cache" options into a single implementation, making them synonyms for
backwards compatibility.

[1] https://lists.gnu.org/archive/html/emacs-orgmode/2014-11/msg00690.html
[2] https://lists.gnu.org/archive/html/emacs-orgmode/2020-01/msg00177.html



reply via email to

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