From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: org-refile-targets multiple conditions Date: Fri, 17 Apr 2009 17:58:28 +0200 Message-ID: <6530CF9F-60C4-46A3-9253-D22DA15B8A9C@gmail.com> References: <20524da70904161512r7c248a93q9de11b02274a62bc@mail.gmail.com> Mime-Version: 1.0 (Apple Message framework v930.3) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Luqlp-0002jC-PT for emacs-orgmode@gnu.org; Fri, 17 Apr 2009 12:18:29 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Luqll-0002hm-5P for emacs-orgmode@gnu.org; Fri, 17 Apr 2009 12:18:29 -0400 Received: from [199.232.76.173] (port=60536 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Luqlk-0002hj-Vi for emacs-orgmode@gnu.org; Fri, 17 Apr 2009 12:18:25 -0400 Received: from ey-out-1920.google.com ([74.125.78.149]:63749) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Luqlk-0007M6-0U for emacs-orgmode@gnu.org; Fri, 17 Apr 2009 12:18:24 -0400 Received: by ey-out-1920.google.com with SMTP id 13so182910eye.24 for ; Fri, 17 Apr 2009 09:18:22 -0700 (PDT) In-Reply-To: <20524da70904161512r7c248a93q9de11b02274a62bc@mail.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: Samuel Wales Cc: emacs-orgmode@gnu.org Hi Samuel, do not want to make the criteria in org-refile-targets any more complex. But you can now write a verification function and put it into the new variable org-refile-target-verify-function. HTH - Carsten On Apr 17, 2009, at 12:12 AM, Samuel Wales wrote: > I want to eliminate DONE and similar states > from the list of refile targets. The benefits would be: > > 1) The set of candidates is reduced, requiring fewer > keystrokes to select a target. > 2) The possibility of misfiling into a task that will be > archived is reduced. > 3) The list length is reduced, helping to work around some > of the speed problems that I have been experiencing with > ido. This is possibly at the cost of slower creation of the > initial list, however. > > The documentation for org-refile-targets says: > >> - a cons cell (:todo . "KEYWORD") to identify refile >> targets by todo keyword. > > In principle I might get the desired behavior by including > all kw /except/ doneish ones, and also including the empty > string. > > But if I did so, I don't think it would work, because I > already set (:maxlevel . 5). I did not find a way to > specify that I want non-doneish entries (including blank) > that are below level 6. > > Would it be feasible to allow AND and NOT? > > (setq org-refile-targets > `((,(file-expand-wildcards (substitute-in-file-name "$dorg/ > *.org")) > . (and (:maxlevel . 5) > (not (:todo . "DONE")) > (not (:todo . "MOST")) > (not (:todo . "MOOT")) > (not (:todo . "DUPLICATE"))))))[fn:13] > > Or is there a way that I can do this with existing org? > > Thanks. > > [fn:13] Or (not (todo "DONE")) or (not (or (todo "DONE") > ...). > > -- > Myalgic encephalomyelitis denialism is causing death and severe > suffering > worse than MS. Greed is corrupting science into foul nonsense. > Anybody can > get the disease at any time permanently. Do science and justice > matter to > you? http://www.meactionuk.org.uk/What_Is_ME_What_Is_CFS.htm > > > _______________________________________________ > Emacs-orgmode mailing list > Remember: use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode