mirror of
https://github.com/org-roam/org-roam
synced 2025-08-01 12:17:21 -05:00
(fix): allow group templates in capture-templates (#584)
Co-authored-by: N V <44036031+progfolio@users.noreply.github.com>
This commit is contained in:
@ -43,6 +43,21 @@ Like `with-temp-buffer', but propagates `org-roam-directory'."
|
||||
(let ((org-roam-directory ,current-org-roam-directory))
|
||||
,@body)))))
|
||||
|
||||
(defmacro org-roam--with-template-error (templates &rest body)
|
||||
"Eval BODY, and point to TEMPLATES on error.
|
||||
Provides more informative error messages so that users know where
|
||||
to look.
|
||||
|
||||
\(fn TEMPLATES BODY...)"
|
||||
(declare (debug (form body)) (indent 1))
|
||||
`(condition-case err
|
||||
,@body
|
||||
(error (user-error "%s. Please adjust `%s'"
|
||||
(error-message-string err)
|
||||
,templates))))
|
||||
|
||||
|
||||
|
||||
(provide 'org-roam-macs)
|
||||
|
||||
;;; org-roam-macs.el ends here
|
||||
|
Reference in New Issue
Block a user