[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: time-warping - retroactively marking DONE?

From: Kyle Meyer
Subject: Re: time-warping - retroactively marking DONE?
Date: Wed, 08 Jul 2020 00:53:01 -0400

Adam Spiers writes:

> I'm looking for a way to retroactively mark a task as having been done
> at a previous time/date.  I know that I can just change the keyword to
> DONE and then edit the timestamp, but this is tedious when it's a
> repeating event, e.g.:

I'm not aware of any built-in support for this.

> If this is not currently possible, would it make sense to write a
> wrapper around `org-todo', e.g. `org-todo-timewarp' or
> `org-retroactive-todo', which interactively prompts for a timestamp
> before invoking `org-todo'?

I think this is the easiest approach, though I'm not sure such a wrapper
needs to live in Org proper.  Here's a snippet from a recent thread [*]
that should get you most of the way there:

    (defun my-org-todo-time-machine ()
      (cl-letf (((symbol-function 'current-time)
                 (lambda ()
                   (apply #'encode-time (org-parse-time-string
                                         "2019-11-27 Mi 16:44")))))
        (call-interactively #'org-todo)))

[*] https://orgmode.org/list/875zj42rpx.fsf@passepartout.tim-landscheidt.de/T/#u

reply via email to

[Prev in Thread] Current Thread [Next in Thread]