Hello, Van L <van@scratch.space> writes:
> 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. Files are selected by their extension, not by their major mode. You may want to tweak `org-file-apps'. Regards, -- Nicolas Goaziou