diff --git a/etc/ORG-NEWS b/etc/ORG-NEWS index a1efc445f..483a1c0c7 100644 --- a/etc/ORG-NEWS +++ b/etc/ORG-NEWS @@ -60,6 +60,23 @@ all the references are resolved in the generated png. # This also includes changes in function behavior from Elisp perspective. ** Miscellaneous +*** Trailing =-= is now allowed in plain links + +Previously, plain links like + +: https://domain/test- + +did not include the trailing =-= punctuation. + +Now, the =-= is allowed at the end, and is considered a part of the plain link. + +#+begin_quote +These types of links will likely be encountered for sites where anchor +targets are automatically generated from documentation headings which +are questions. + https://list.orgmode.org/orgmode/87sexh9ddv.fsf@ice9.digital/ +#+end_quote + *** =org-attach= now considers symlinked files when searching pre-existing attach dirs When Org buffer is opened from a symlink, Org mode looks into the diff --git a/lisp/ol.el b/lisp/ol.el index 514d5c81f..a8a59ddaa 100644 --- a/lisp/ol.el +++ b/lisp/ol.el @@ -944,6 +944,12 @@ This should be called after the variable `org-link-parameters' has changed." (1+ (or (regex ,non-space-bracket) ,parenthesis)) (or (regexp "[^[:punct:] \t\n]") + ;; Allow "-" punctuation, as an exception + ;; See https://list.orgmode.org/orgmode/87sexh9ddv.fsf@ice9.digital/ + ;; This is also in line with the heuristics + ;; above - it also does not include "-" + ;; punctuation. + ?- ?/ ,parenthesis))))) org-link-bracket-re