From: Carsten Dominik Date: Tue, 21 Mar 2006 13:36:56 +0000 (+0000) Subject: (org-open-at-point): Fixed bug in wiki-style bracket links. X-Git-Tag: emacs-pretest-22.0.90~3476 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c0434d3b46c55c7128b2f80e7b908348b22c1eb8;p=emacs.git (org-open-at-point): Fixed bug in wiki-style bracket links. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3cf352ce757..4c325e968ca 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,6 @@ 2006-03-21 Carsten Dominik - * textmodes/org.el: (org-open-at-point): Fixed bug in wiki-stype + * textmodes/org.el: (org-open-at-point): Fixed bug in wiki-style bracket links. 2006-03-21 Kim F. Storm diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index a00a1b247e8..ad4744adf15 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -6833,8 +6833,8 @@ optional argument IN-EMACS is non-nil, Emacs will visit the file." (while (string-match " *\n *" link) (setq link (replace-match " " t t link))) (if (string-match org-link-regexp link) - (setq type (match-string 1) - path (match-string 2)) + (setq type (match-string 1 link) + path (match-string 2 link)) (setq type "thisfile" path link)) (throw 'match t))) @@ -6893,6 +6893,10 @@ optional argument IN-EMACS is non-nil, Emacs will visit the file." (cond + ((member type '("http" "https" "ftp" "mailto" "news")) + ;; give these to some browser + (browse-url (concat type ":" path))) + ((string= type "tags") (org-tags-view in-emacs path)) ((or (string= type "camel")