From 9e567685227928d64e5e0bdc5edc72ac572e1d55 Mon Sep 17 00:00:00 2001 From: Random936 Date: Mon, 27 Nov 2023 21:04:52 -0800 Subject: [PATCH] Updated dynamic habits to use org-capture relative time --- .emacs.d/functions.org | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.emacs.d/functions.org b/.emacs.d/functions.org index 47365d4..391f0b9 100644 --- a/.emacs.d/functions.org +++ b/.emacs.d/functions.org @@ -18,11 +18,12 @@ These functions are for my org roam daily capture template. (mapconcat #'identity (delq nil (org-map-entries #'jm/daily-todos-priority-tasks-helper - "/TODO=\"IN PROGRESS\"/" + "TODO=\"IN PROGRESS\"" files)) "\n")) (defun jm/daily-todos-dynamic-habits (habit week-days) - (let ((today (downcase (format-time-string "%a")))) + (let* ((org-date (or (org-capture-get :default-time) (current-time))) + (today (downcase (format-time-string "%a" org-date)))) (when (seq-contains-p week-days today) habit))) #+end_src