From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: link handling for `file:' fails to stay within Emacs but calls `open file:' with TextEdit Date: Fri, 25 May 2018 00:57:31 +0200 Message-ID: <871se0r7ac.fsf@nicolasgoaziou.fr> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39103) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fLzAy-0002gP-2M for emacs-orgmode@gnu.org; Thu, 24 May 2018 18:57:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fLzAt-0004Te-8f for emacs-orgmode@gnu.org; Thu, 24 May 2018 18:57:40 -0400 Received: from relay4-d.mail.gandi.net ([217.70.183.196]:57931) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fLzAt-0004T6-2E for emacs-orgmode@gnu.org; Thu, 24 May 2018 18:57:35 -0400 In-Reply-To: (Van L.'s message of "Wed, 9 May 2018 13:02:07 +1000") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Van L Cc: emacs-orgmode@gnu.org Hello, Van L 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 th= e 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=E2=80=99 extension > ;; to follow `file:=E2=80=99 links without leaving Emacs. Files are selected by their extension, not by their major mode. You may want to tweak `org-file-apps'. Regards, --=20 Nicolas Goaziou