mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-12-03 08:30:03 +00:00
Merge branch 'maint'
This commit is contained in:
commit
37e3c112dd
43
lisp/org.el
43
lisp/org.el
@ -5670,34 +5670,29 @@ stacked delimiters is N. Escaping delimiters is not possible."
|
||||
"Update the link regular expressions.
|
||||
This should be called after the variable `org-link-types' has changed."
|
||||
(setq org-link-types-re
|
||||
(concat
|
||||
"\\`\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):")
|
||||
(concat "\\`" (regexp-opt org-link-types t) ":\\(?://\\)")
|
||||
org-link-re-with-space
|
||||
(concat
|
||||
"<?\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^" org-non-link-chars "]*"
|
||||
"[^" org-non-link-chars " ]\\)>?")
|
||||
(concat "<?" (regexp-opt org-link-types t) ":\\(?://\\)"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^" org-non-link-chars "]*"
|
||||
"[^" org-non-link-chars " ]\\)>?")
|
||||
org-link-re-with-space2
|
||||
(concat
|
||||
"<?\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^\t\n\r]*"
|
||||
"[^" org-non-link-chars " ]\\)>?")
|
||||
(concat "<?" (regexp-opt org-link-types t) ":\\(?://\\)?"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^\t\n\r]*"
|
||||
"[^" org-non-link-chars " ]\\)>?")
|
||||
org-link-re-with-space3
|
||||
(concat
|
||||
"<?\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^\t\n\r]*\\)")
|
||||
(concat "<?" (regexp-opt org-link-types t) ":\\(?://\\)?"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^\t\n\r]*\\)")
|
||||
org-angle-link-re
|
||||
(concat
|
||||
"<\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^" org-non-link-chars "]*"
|
||||
"\\)>")
|
||||
(concat "<" (regexp-opt org-link-types t) ":\\(?://\\)?"
|
||||
"\\([^" org-non-link-chars " ]"
|
||||
"[^" org-non-link-chars "]*"
|
||||
"\\)>")
|
||||
org-plain-link-re
|
||||
(concat
|
||||
"\\<\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):"
|
||||
"\\<" (regexp-opt org-link-types t) ":\\(?://\\)?"
|
||||
(org-re "\\([^ \t\n()<>]+\\(?:([[:word:]0-9_]+)\\|\\([^[:punct:] \t\n]\\|/\\)\\)\\)"))
|
||||
;; "\\([^]\t\n\r<>() ]+[^]\t\n\r<>,.;() ]\\)")
|
||||
org-bracket-link-regexp
|
||||
@ -5705,7 +5700,7 @@ This should be called after the variable `org-link-types' has changed."
|
||||
org-bracket-link-analytic-regexp
|
||||
(concat
|
||||
"\\[\\["
|
||||
"\\(\\(" (mapconcat 'regexp-quote org-link-types "\\|") "\\):\\)?"
|
||||
"\\(" (regexp-opt org-link-types t) ":\\(?://\\)?\\)?"
|
||||
"\\([^]]+\\)"
|
||||
"\\]"
|
||||
"\\(\\[" "\\([^]]+\\)" "\\]\\)?"
|
||||
@ -5713,7 +5708,7 @@ This should be called after the variable `org-link-types' has changed."
|
||||
org-bracket-link-analytic-regexp++
|
||||
(concat
|
||||
"\\[\\["
|
||||
"\\(\\(" (mapconcat 'regexp-quote (cons "coderef" org-link-types) "\\|") "\\):\\)?"
|
||||
"\\(" (regexp-opt (cons "coderef" org-link-types) t) ":\\(?://\\)?\\)?"
|
||||
"\\([^]]+\\)"
|
||||
"\\]"
|
||||
"\\(\\[" "\\([^]]+\\)" "\\]\\)?"
|
||||
|
@ -1362,12 +1362,10 @@ e^{i\\pi}+1=0
|
||||
;; ... with expansion.
|
||||
(should
|
||||
(equal
|
||||
"//orgmode.org/worg"
|
||||
"orgmode.org/worg"
|
||||
(org-test-with-temp-text "[[Org:worg]]"
|
||||
(let ((org-link-abbrev-alist '(("Org" . "http://orgmode.org/"))))
|
||||
(org-element-property
|
||||
:path
|
||||
(org-element-map (org-element-parse-buffer) 'link 'identity nil t))))))
|
||||
(org-element-property :path (org-element-context))))))
|
||||
;; ... with translation.
|
||||
(should
|
||||
(equal
|
||||
|
Loading…
Reference in New Issue
Block a user