emacs-orgmode
[Top][All Lists]
Advanced

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

How to mark task as done at specified (past) time?


From: Tim Landscheidt
Subject: How to mark task as done at specified (past) time?
Date: Thu, 28 Nov 2019 10:57:46 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)

Hi,

with Emacs 26.2/org-mode 9.1.9, I have a repeating task that
I close with a helper function:

| (defun tl-entry-done ()
|   (interactive)
|   (find-file "/path/to/file.org")
|   (goto-char (org-find-entry-with-id "ENTRY-ID"))
|   (org-todo 'done))

Every time I do this task, I get an acknowledging mail, so
instead of manually closing this task (and forgetting to do
that, or delaying it for some time) I want Gnus to mark the
task as done /at the time when the mail was sent/, i. e. in:

|    - State "DONE"       from "TODO"       [2019-11-27 Mi 16:44]

I want "2019-11-27 Mi 16:44" not to be the current time, but
some other (past) time.

How can I mark a task as done at a specified time?  Looking
at org-add-planning-info, there seems to be a mechanism to
pass a timestamp, but it does not seem to be exposed at
higher levels (?).

Do I have to cl-flet org-current-time or something similar?

Tim




reply via email to

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