branch: externals/denote commit 39d98706356b97eaea7932b553954feba3ea5cda Author: Protesilaos Stavrou <i...@protesilaos.com> Commit: Protesilaos Stavrou <i...@protesilaos.com>
Change punct regexp location; make it defconst --- denote.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/denote.el b/denote.el index 40932af173..72904f2a9e 100644 --- a/denote.el +++ b/denote.el @@ -105,6 +105,9 @@ define." (defconst denote-keyword-regexp "\\(--\\)\\([0-9A-Za-z_+]*\\)\\(--\\)" "Regular expression to match `denote-keywords'.") +(defconst denote--punctuation-regexp "[][{}!@#$%^&*()_=+'\"?,.\|;:~`‘’“”]*" + "Regular expression of punctionation that should be removed.") + (defvar denote-last-path nil "Store last path.") (defvar denote-last-title nil "Store last title.") (defvar denote-last-keywords nil "Store last keywords.") @@ -130,9 +133,6 @@ define." (when (re-search-forward regexp nil t -1) (match-string (or group 1))))) -(defvar denote--punctuation-regexp "[][{}!@#$%^&*()_=+'\"?,.\|;:~`‘’“”]*" - "Regular expression of punctionation that should be removed.") - (defun denote--slug-no-punct (str) "Convert STR to a file name slug." (replace-regexp-in-string denote--punctuation-regexp "" str))