branch: externals/denote commit ff50b322588a4e023aaf5e0b35ecf1ad0013b653 Author: Protesilaos Stavrou <i...@protesilaos.com> Commit: Protesilaos Stavrou <i...@protesilaos.com>
Revise "link in context" regexp to also cover query links --- denote.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/denote.el b/denote.el index 8a66d9e66d..59c7dabe84 100644 --- a/denote.el +++ b/denote.el @@ -4760,7 +4760,7 @@ Also see `denote-id-only-link-in-context-regexp'.") (defvar denote-org-link-in-context-regexp (concat "\\[\\[" "denote:" - "\\(?1:" denote-id-regexp "\\)" + "\\(?1:[^][]*?\\)" "\\(?:::.*\\)?" "]" "\\[" "\\(?2:" ".*?" "\\)" "]]") "Regexp to match an Org link in its context. @@ -4768,12 +4768,12 @@ The format of such links is `denote-org-link-format'.") (defvar denote-md-link-in-context-regexp (concat "\\[" "\\(?2:" ".*?" "\\)" "]" - "(denote:" "\\(?1:" denote-id-regexp "\\)" ")") + "(denote:" "\\(?1:[^][]*?\\)" ")") "Regexp to match a Markdown link in its context. The format of such links is `denote-md-link-format'.") (defvar denote-id-only-link-in-context-regexp - (concat "\\[\\[" "denote:" "\\(?1:" denote-id-regexp "\\)" "]]") + (concat "\\[\\[" "denote:" "\\(?1:[^][]*?\\)" "]]") "Regexp to match an identifier-only link in its context. The format of such links is `denote-id-only-link-format'." )