Kaushal Modi <kaushal.m...@gmail.com> writes: > Here are a couple of ideas: > > - Let's assume that if the current file name is /path/to/foo.org, the > SETUPFILE is always downloaded to /tmp/path_to_foo_config.org for brevity. > The function that sets that temp file should be a defcustom.
What about storing the contents of the file in a variable instead of cluttering the temp directory? > - Now, the referenced SETUPFILE should be downloaded only if that (1) That > file is being fetched for the first time in that emacs session, or (2) that > temp file does not exist. And (3) it isn't local? > - Add a defun to force reload the SETUPFILE from the referenced URL, in > which case the temp file will be deleted and re-downloaded (as the above > condition satisfied). > > So under the normal circumstance where that foo.org file buffer is reverted > multiple times in an emacs session, the same SETUPFILE downloaded to /tmp > will be used. If the user updated the file at the referenced URL, they can > do the above mentioned forced reload of SETUPFILE and download the latest > version of SETUPFILE. > > Thoughts? It could work. Do you want to provide an implementation? Regards,