summaryrefslogtreecommitdiffhomepage
path: root/lib/doc/jao-org-notes.el
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2025-11-28 13:12:09 +0000
committerjao <jao@gnu.org>2025-11-28 13:12:09 +0000
commit6582785a4004fe68c79219c690aaafdc8ec5a240 (patch)
tree6b685b4688314f0b6c2f49b7e4dd640656fe1d06 /lib/doc/jao-org-notes.el
parent1b0e0ce333bae2d3befa2d15551dd2cd77b3dc3c (diff)
downloadelibs-6582785a4004fe68c79219c690aaafdc8ec5a240.tar.gz
elibs-6582785a4004fe68c79219c690aaafdc8ec5a240.tar.bz2
jao-org-notes: capture templates with notes file fixed
Diffstat (limited to 'lib/doc/jao-org-notes.el')
-rw-r--r--lib/doc/jao-org-notes.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/doc/jao-org-notes.el b/lib/doc/jao-org-notes.el
index 4b45eab..0b2c65b 100644
--- a/lib/doc/jao-org-notes.el
+++ b/lib/doc/jao-org-notes.el
@@ -188,7 +188,7 @@ appear in any order in the tags list.
(init (concat "^..tags: " (mapconcat #'identity tags " "))))
(jao-org-notes-consult-ripgrep init)))
-(defun jao-org-notes-create (&optional title)
+(defun jao-org-notes-create (&optional title ret-buffer)
"Create a new note file, matching tags and titles with completion."
(interactive)
(when (jao-org-notes--insert-title title)
@@ -197,7 +197,7 @@ appear in any order in the tags list.
":\n")
(org-insert-time-stamp (current-time) t t "#+date: " "\n"))
(save-buffer)
- (current-buffer))
+ (if ret-buffer (current-buffer) (buffer-file-name)))
(defun jao-org-notes-backlinks ()
"Show a list of note files linking to the current one."