Buttonize all links when inserted in bulk

This commit is contained in:
Protesilaos Stavrou 2022-06-20 07:17:00 +03:00
parent 75cf3d31d0
commit 7074b25869
No known key found for this signature in database
GPG key ID: 99BD6459CD5CA3EA

View file

@ -375,7 +375,9 @@ inserts links with just the identifier."
(let* ((default-directory (denote-directory))
(ext (denote-link--extension-format-or-id id-only)))
(if-let ((files (denote--directory-files-matching-regexp regexp)))
(insert (denote-link--prepare-links files ext))
(let ((beg (point)))
(insert (denote-link--prepare-links files ext))
(denote-link-buttonize-buffer beg (point)))
(user-error "No links matching `%s'" regexp))))
(defalias 'denote-link-insert-links-matching-regexp (symbol-function 'denote-link-add-links))