From: Matt Lundin <mdl@imapmail.org>
To: Nathaniel Flath <flat0103@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Remove scheduled date when switch TODO states
Date: Mon, 22 Feb 2010 13:10:06 -0500 [thread overview]
Message-ID: <87sk8tcfb5.fsf@fastmail.fm> (raw)
In-Reply-To: <5e3a506e1002201213i1e14bad3q844adeb6fa04cc4c@mail.gmail.com> (Nathaniel Flath's message of "Sat, 20 Feb 2010 12:13:44 -0800")
Nathaniel Flath <flat0103@gmail.com> writes:
> I have a todo state, PENDING, that I organize tasks that I cannot
> perform immediately. Is there a way to configure org-todoconfigure so
> that when a task is switched to PENDING, if it has a scheduled date
> that date is removed?
You could use the hook org-after-todo-state-change-hook. E.g.
--8<---------------cut here---------------start------------->8---
(defun my-org-pending-remove-deadline ()
(when (equal (org-entry-get nil "TODO") "PENDING")
(org-remove-timestamp-with-keyword org-deadline-string)))
(add-hook 'org-after-todo-state-change-hook 'my-org-pending-remove-deadline)
--8<---------------cut here---------------end--------------->8---
Best,
Matt
next prev parent reply other threads:[~2010-02-22 18:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-20 20:13 Remove scheduled date when switch TODO states Nathaniel Flath
2010-02-21 5:18 ` Manish
2010-02-22 18:10 ` Matt Lundin [this message]
2010-02-22 22:19 ` David Maus
2010-02-22 22:23 ` Matthew Lundin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87sk8tcfb5.fsf@fastmail.fm \
--to=mdl@imapmail.org \
--cc=emacs-orgmode@gnu.org \
--cc=flat0103@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).