[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Orgmode] [PATCH] Fix broken internal links on export
From: |
Jambunathan K |
Subject: |
[Orgmode] [PATCH] Fix broken internal links on export |
Date: |
Tue, 12 Oct 2010 21:30:12 +0530 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.91 (windows-nt) |
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.
<p>
-There is a link to <a href="#Heading==1">Heading 1</a> here.
+There is a link to <a href="#sec-1">Heading 1</a> here.
</p></div>
</div>
Note:
Is 'dedicated the right value to return?
Jambunathan K.
>From 82fcc473277c2a1c5647820c19eff0f0e11582c9 Mon Sep 17 00:00:00 2001
From: Jambunathan K <address@hidden>
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
- [Orgmode] [PATCH] Fix broken internal links on export,
Jambunathan K <=