branch: externals/org
commit 036e8dcf0463517749f8b32ca828b923e584625f
Author: Ihor Radchenko <yanta...@posteo.net>
Commit: Ihor Radchenko <yanta...@posteo.net>

    org-id-locations-load: Keep file names abbreviated
    
    * lisp/org-id.el (org-id-locations-load): Abbreviate relative file
    names to keep things consistent with what `org-id-add-location' does.
    
    Reported-by: Martin Edström <meedst...@runbox.eu>
    Link: https://orgmode.org/list/E1stuQI-0006YG-64@rmmprod06.runbox
---
 lisp/org-id.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lisp/org-id.el b/lisp/org-id.el
index 17568ab314..720e489c80 100644
--- a/lisp/org-id.el
+++ b/lisp/org-id.el
@@ -631,7 +631,10 @@ If SILENT is non-nil, messages are suppressed."
            (let ((loc (file-name-directory org-id-locations-file)))
              (mapc (lambda (item)
                      (unless (file-name-absolute-p (car item))
-                       (setf (car item) (expand-file-name (car item) loc))))
+                       (setf (car item)
+                              ;; Abbreviate as `org-id-add-location' does.
+                              (abbreviate-file-name
+                               (expand-file-name (car item) loc)))))
                    org-id-locations)))
        (error
          (message "Could not read `org-id-locations' from %s, setting it to 
nil"

Reply via email to