Brady Trainor <[email protected]> writes:
>
> A solution would be to use file+headline, then not using :prepend
> prevents an extra line, but my headline is the date and varies.
>
I solved my problem this way by modifying the function
insert-date-N-days-from-current to print instead of insert. Now I can use
file+headline and avoid :prepend.
#+BEGIN_SRC emacs-lisp
(defun print-date-N-days-from-current (&optional days)
"Print date that is DAYS from current."
(interactive "p*")
(print
(calendar-date-string
(calendar-gregorian-from-absolute
(+ (calendar-absolute-from-gregorian (calendar-current-date))
days)))))
(setq org-capture-templates
`(("p" "pomodoro, checklist"
checkitem (file+headline ,pomodoro ,(print-date-N-days-from-current 0))
"")))
#+END_SRC
--
Brady