emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Orgmode] sorting entries on date created?


From: Nick Dokos
Subject: Re: [Orgmode] sorting entries on date created?
Date: Wed, 29 Apr 2009 13:41:54 -0400

Marko Schütz <address@hidden> wrote:

> I use remember to add todo entries. Mine look like this
> 
> ** TODO kpdf as standard pdf viewer from auctex
>    [2008-07-19 Sat]
> 
> where the inactive timestamp is added at creation.
> 
> I'd like to use org-sort to sort such entries by creation date. I'd
> assume I could use sorting-type ?f with a suitable getkey-func. So, is
> there already a function in org that I could use to extract this date?
> 

Not sure if this helps (it does not answer your question directly):

There are two places in org-sort-entries-or-items (which is called by
org-sort under the conditions at hand) where a regexp, org-ts-regexp, is
used when sorting-type is selected to be ?t: one is for when you are
sorting plain lists and the other is when you are sorting top-level
entries or the active region. If you change the relevant instance of
org-ts-regexp to org-ts-regexp-both, it will match both active and
inactive timestamps and sort appropriately. I have not tried to figure
out what happens if there are multiple timestamps, active or inactive,
in an entry. But if you just have a single inactive timestamp per entry,
as you have indicated above, that should work.

HTH,
Nick





reply via email to

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