[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6
From: |
Al Haji-Ali |
Subject: |
Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)] |
Date: |
Mon, 17 Jun 2024 22:52:20 +0100 |
On 17/06/2024, Ihor Radchenko wrote:
> Makes sense.
> May you prepare a patch with the proposed change?
> See https://orgmode.org/worg/org-contribute.html#first-patch
It's not really a long patch, just involves calling `file-truename` instead of
`expand-file-name` in a couple of places.
diff --git a/lisp/org-refile.el b/lisp/org-refile.el
index 20b5fbd02..7c463bc67 100644
--- a/lisp/org-refile.el
+++ b/lisp/org-refile.el
@@ -324,7 +324,7 @@ When `org-refile-use-cache' is nil, just return POS."
(progn
(when (bufferp f)
(setq f (buffer-file-name (buffer-base-buffer f))))
- (setq f (and f (expand-file-name f)))
+ (setq f (and f (file-truename f)))
(when (eq org-refile-use-outline-path 'file)
(push (list (and f (file-name-nondirectory f)) f nil nil) tgs))
(when (eq org-refile-use-outline-path 'buffer-name)
@@ -666,7 +666,7 @@ this function appends the default value from
#'completing-read))
(extra (if org-refile-use-outline-path "/" ""))
(cbnex (concat (buffer-name) extra))
- (filename (and cfn (expand-file-name cfn)))
+ (filename (and cfn (file-truename cfn)))
(tbl (mapcar
(lambda (x)
(if (and (not (member org-refile-use-outline-path
-- Al
- [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Al Haji-Ali, 2024/06/17
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Ihor Radchenko, 2024/06/17
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)],
Al Haji-Ali <=
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Ihor Radchenko, 2024/06/18
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Al Haji-Ali, 2024/06/18
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Ihor Radchenko, 2024/06/19
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Al Haji-Ali, 2024/06/20
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Ihor Radchenko, 2024/06/20
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Al Haji-Ali, 2024/06/20
- Re: [BUG] org-refile-get-location a symlinked file [9.7-pre (release_9.6.29-1443-gb4d17c)], Ihor Radchenko, 2024/06/20