[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] link handling for `file:' fails to stay within Emacs but calls `open
From: |
Van L |
Subject: |
[O] link handling for `file:' fails to stay within Emacs but calls `open file:' with TextEdit |
Date: |
Wed, 9 May 2018 13:02:07 +1000 |
Hello.
The link handling for org mode behaves unexpectedly where a file sets
org mode according to `Local variables:' at the end of the file.
In the following, a.org and b.org files work as expected using M-x
org-store-link and M-x org-insert-link for `file:' link.
Without the .org filename extension, following the link calls
`open file:' which leads to Org Mode opening the file with TextEdit
under mac os, Emacs 26.1 rc-1.
;;;; ------------------------------------
;; running : Emacs.app/Contents/MacOS/Emacs -Q
;; problem : This two file arrangment for `Emacs -Q' *fails* to follow the
link.
;; expect : Emacs to open a link to org file.
;; unexpected : Emacs calls TextEdit to open org file.
;; solution : if file a and b are called a.org and b.org then there is no
problem.
;; Solution needs org files named without the `.org’ extension
;; to follow `file:’ links without leaving Emacs.
;;;; ------------------------------------
;; file : a
* one
** two
*** three
[[file:b::*title%20%E4%B8%AD][title 中]]
# Local variables:
# mode: org
# End:
;;;; ------------------------------------
;; file : b
* work
** title 中
*** chapter
# Local variables:
# mode: org
# End:
;;;; ============================================================
;; file a.org
* one
** two
*** three
[[file:b.org::*title%20%E4%B8%AD][title 中]]
;;;; ============================================================
;; file b.org
* work
** title 中
*** chapter
- [O] link handling for `file:' fails to stay within Emacs but calls `open file:' with TextEdit,
Van L <=