summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <mail@nicolasgoaziou.fr>2018-11-17 21:45:16 +0100
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2018-11-17 21:45:16 +0100
commitfc9cf62bf3932ef9d8b6e8cb5371dafaffd7ec24 (patch)
treef4f5ed7b34920570a43b89d82de904585adcd9da
parent7bf3c108197e59a76c0b51518ed5d3b0012d9d66 (diff)
downloadorg-mode-fc9cf62bf3932ef9d8b6e8cb5371dafaffd7ec24.tar.gz
org-clock: Fix special strings in :tstart and :tend
* lisp/org-clock.el (org-clocktable-steps): Handle relative time strings like "<-1w>".
-rw-r--r--lisp/org-clock.el6
1 files changed, 2 insertions, 4 deletions
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index 672523f..60dccc2 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -2710,15 +2710,13 @@ The TS argument has the same type as the return values of
;; org-agenda.
(pcase-let ((`(,month ,day ,year) (calendar-gregorian-from-absolute ts)))
(setq ts (float-time (encode-time 0 0 0 day month year)))))
- (ts
- (setq ts (float-time (apply #'encode-time (org-parse-time-string ts))))))
+ (ts (setq ts (org-matcher-time ts))))
(cond
((numberp te)
;; Likewise for te.
(pcase-let ((`(,month ,day ,year) (calendar-gregorian-from-absolute te)))
(setq te (float-time (encode-time 0 0 0 day month year)))))
- (te
- (setq te (float-time (apply #'encode-time (org-parse-time-string te))))))
+ (te (setq te (org-matcher-time te))))
(setq tsb
(if (eq step0 'week)
(let ((dow (nth 6 (decode-time (seconds-to-time ts)))))