From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jambunathan K Subject: [PATCH] Fix broken internal links on export Date: Tue, 12 Oct 2010 21:30:12 +0530 Message-ID: <81mxqj1jw3.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from [140.186.70.92] (port=40509 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P5hHJ-0007E4-Ay for emacs-orgmode@gnu.org; Tue, 12 Oct 2010 12:00:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P5hHI-00035j-3P for emacs-orgmode@gnu.org; Tue, 12 Oct 2010 12:00:37 -0400 Received: from mail-pv0-f169.google.com ([74.125.83.169]:61438) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P5hHH-00035V-V0 for emacs-orgmode@gnu.org; Tue, 12 Oct 2010 12:00:36 -0400 Received: by pvf33 with SMTP id 33so437432pvf.0 for ; Tue, 12 Oct 2010 09:00:34 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --=-=-= Summary: Fix broken internal links on export Test case. (setq org-link-search-must-match-exact-headline t) # file temp.org * Heading 1 Some content. * Heading 2 There is a link to [[Heading 1]] here. Export this to html and note that [[Heading 1]] is wrongly translated. Apply the patch. See that the internal link is correctly exported.

-There is a link to Heading 1 here. +There is a link to Heading 1 here.

Note: Is 'dedicated the right value to return? Jambunathan K. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Fix-broken-internal-links-on-export.patch Content-Description: patch >From 82fcc473277c2a1c5647820c19eff0f0e11582c9 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Tue, 12 Oct 2010 21:17:09 +0530 Subject: [PATCH] Fix broken internal links on export * org.el (org-link-search): Return 'dedicated on successful match when org-link-search-must-match-exact-headline is set to t. --- lisp/org.el | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index a80286f..f0ad595 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -9389,6 +9389,7 @@ in all files. If AVOID-POS is given, ignore matches near that position." (regexp-quote s)) nil t)) ;; OK, found a match + (setq type 'dedicated) (goto-char (match-beginning 0))) ((and (not org-link-search-inhibit-query) (eq org-link-search-must-match-exact-headline 'query-to-create) -- 1.7.2.3 --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --=-=-=--