summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Lee <jjl@pobox.com>2019-02-03 12:36:03 +0000
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2019-02-06 22:29:29 +0100
commitba9111a7de9752d36b275940583e0f1631b2fa35 (patch)
tree365e32a050195e847e8d541e5801acc2e71ff0ab
parentba1fba147f0ad14319870cb49a2e2675c8462f2b (diff)
downloadorg-mode-ba9111a7de9752d36b275940583e0f1631b2fa35.tar.gz
org-habit: Always show time of day designation for habits
* org-agenda.el (org-agenda-get-scheduled): Always show the time of day designation for habits TINYCHANGE
-rw-r--r--lisp/org-agenda.el14
1 files changed, 11 insertions, 3 deletions
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 784a555..203c1e9 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -6257,9 +6257,17 @@ scheduled items with an hour specification like [h]h:mm."
(head (buffer-substring (point) (line-end-position)))
(time
(cond
- ;; No time of day designation if it is only
- ;; a reminder.
- ((and (/= current schedule) (/= current repeat)) nil)
+ ;; No time of day designation if it is only a
+ ;; reminder, except for habits, which always show
+ ;; the time of day. Habits are an exception
+ ;; because if there is a time of day, that is
+ ;; interpreted to mean they should usually happen
+ ;; then, even if doing the habit was missed.
+ ((and
+ (not habitp)
+ (/= current schedule)
+ (/= current repeat))
+ nil)
((string-match " \\([012]?[0-9]:[0-9][0-9]\\)" s)
(concat (substring s (match-beginning 1)) " "))
(t 'time)))