Hi, I'm trying to set up a capture template of type "function" in order to produce a daily log file named after today's date.
It mostly works. However, after doing the C-cC-c to close the capture
buffer the window is left holding the daily log file which the capture
just updated instead of going back to whatever buffer I was in when I
initiated the capture. This returning-to-previous-buffer behavior is
what I see when I use the file+headline capture type.
Can someone say how I might get this behavior for the "function" capture
type as well? Here is my setup:
(defun bv-daily-log-file ()
(find-file (concat "~/org/web/notes/"
(format-time-string "%Y-%m-%d") ".org"))
(goto-char (point-max))
(newline 2)
)
(setq org-capture-templates
(quote
(
("n" "Note" entry
(function bv-daily-log-file)
"\* %U %^{title}\n %a\n\n%?"
:empty-lines 1)
)))
Thanks,
-Brett.
pgp3fjuT9LesZ.pgp
Description: PGP signature
