From mboxrd@z Thu Jan 1 00:00:00 1970 From: Manish Subject: Re: wish list: sort tasks by age Date: Wed, 1 Jul 2009 13:40:21 +0530 Message-ID: References: <9FE27D7D-3CB3-4B17-9061-0AFF0FCD0AFF@contrapunctus.net> <87tz1wzy1o.wl%maus.david@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MLutz-0006zy-8V for emacs-orgmode@gnu.org; Wed, 01 Jul 2009 04:10:47 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MLutu-0006tg-L2 for Emacs-orgmode@gnu.org; Wed, 01 Jul 2009 04:10:46 -0400 Received: from [199.232.76.173] (port=37426 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MLutu-0006td-CM for Emacs-orgmode@gnu.org; Wed, 01 Jul 2009 04:10:42 -0400 Received: from an-out-0708.google.com ([209.85.132.242]:39611) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MLutu-0001v1-3H for Emacs-orgmode@gnu.org; Wed, 01 Jul 2009 04:10:42 -0400 Received: by an-out-0708.google.com with SMTP id b6so446740ana.21 for ; Wed, 01 Jul 2009 01:10:41 -0700 (PDT) In-Reply-To: <87tz1wzy1o.wl%maus.david@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: David Maus Cc: Emacs-orgmode@gnu.org On Wed, Jul 1, 2009 at 12:31 PM, David Maus wrote: > At Tue, 30 Jun 2009 16:04:39 -0400, > Christopher League wrote: >> >> I would love to be able to sort TODOs by their age, so it becomes >> painfully obvious what I have been ignoring. Since org relies on free- >> form text (a strength), it's tricky to ensure that every item gets a >> 'creation-time' property. But it doesn't need to be accurate to the >> second; even a script that added that property once every day or so >> might do the trick. > > Well, I'm not a elisp hacker but what comes into my mind is a custom > function that does: > > for all headlines with a TODO keyword > > * check if property "creation-time" exists > > * add propertie creation time with current date & time if such an > propertie does not exist > > and then hook this function into before-save-hook. > > So the question is (a) if there are functions to process all items, > check for existence of a property and create properties (I'm quite > certain there are) and (b) how to use them. There are property and mapping APIs documented in the manual under section on hacking. -- Manish