From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Zang Subject: Re: Custom Agenda View for Projects Date: Tue, 15 Mar 2011 22:35:31 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=47732 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pzbtv-0001cX-9L for emacs-orgmode@gnu.org; Tue, 15 Mar 2011 17:35:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pzbtu-0000nS-2r for emacs-orgmode@gnu.org; Tue, 15 Mar 2011 17:35:35 -0400 Received: from mail-vx0-f169.google.com ([209.85.220.169]:38997) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pzbtt-0000n9-Pj for emacs-orgmode@gnu.org; Tue, 15 Mar 2011 17:35:34 -0400 Received: by vxk12 with SMTP id 12so1270512vxk.0 for ; Tue, 15 Mar 2011 14:35:33 -0700 (PDT) In-Reply-To: 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: Manish Cc: emacs-orgmode@gnu.org 2011/3/15 Christian Zang : > 2011/3/15 Manish : >> On Tue, Mar 15, 2011 at 11:54 AM, Christian Zang wrote: >>> 2011/3/15 Manish: >>>> On Tue, Mar 15, 2011 at 12:54 AM, Christian Zang wrote: >>>>> Dear all, >>>>> >>>>> I might be overlooking something very obvious, but I cannot find the >>>>> solution: I have various org files, in which "projects" (anything >>>>> requiring more than one action step...) are first level headings >>>>> marked using the TODO kwd PROJ. If I tell my agenda to list all items >>>>> with kwd PROJ (either via C-a T PROJ or as a custom agenda view via >>>>> "tags-todo "LEVEL=3D1""), only the ones without siblings are returned= . >>>>> I've looked into "org-tags-match-list-sublevels" but this is not quit= e >>>>> the right thing to calibrate... >>>> >>>> Could you show a sample outline please? >>>> >>>> -- >>>> Manish >>>> >>> >>> Sure, here is a sample outline: >>> >>> * PROJ Write Proposal >>> >>> ** TODO write introduction >>> >>> * PROJ Clean Lab >>> >>> * PROJ Get Birthday Present >>> >>> ** TODO get dad's hat size >>> >>> From that list, only "Clean Lab" will show up in the list of projects. >>> Below are my settings regarding custom agenda views: >>> >>> (setq org-agenda-custom-commands >>> =C2=A0 =C2=A0 =C2=A0'(("W" "Weekly Review" >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 ((agenda "" ((org-agenda-ndays 7))) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(stuck "") ;; review stuck projects >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(todo "PROJ") ;; review all projects >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(todo "SDMB") ;; review someday/maybe= items >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(todo "WAIT"))) ;; review waiting ite= ms >>> >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0("P" "Projects" tags-todo "LEVEL=3D1" >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 ((org-agenda-overriding-header "List of Pro= jects"))) >>> >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0("O" "Today-View" =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 ; like OF "due & flagged" >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 ((agenda "Due or scheduled within next week= " >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0((org-age= nda-ndays 7) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (org-age= nda-start-on-weekday nil) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (org-age= nda-overriding-header "\nDue or scheduled >>> within next week\n------------------\n") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 )) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0; due = within next week >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(tags-todo "+PRIORITY=3D\"A\"" >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (= (org-agenda-overriding-header "\nHigh >>> priority\n------------------\n"))) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0; pseu= do-flagged items >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0)) >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0)) >>> >>> Neither "W" nor "P" shows all projects, but rather only the ones >>> without siblings. This is what I use as TODO kwds: >>> >>> (setq org-todo-keywords '((sequence "TODO(t)" "WAIT(w@/!)" "|" "DONE(d!= )") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "STRT(s!)" "|") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "|" "CNCL(c@!)") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "FXME(f)" "|" "FIXD(x!)") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "PROJ(p!)" "PRSC(u)" "PROH(o)" "|" >>> "PRDN(r!)" "PRCL(o@/!)") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "LIST(l)" "|") >>> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(sequence "SDMB(m)" "|"))) >>> >>> And these are the agenda-relevant settings in custom.el: >>> >>> =C2=A0'(org-agenda-compact-blocks t) >>> =C2=A0'(org-agenda-dim-blocked-tasks (quote invisible)) >>> =C2=A0'(org-stuck-projects (quote ("+LEVEL=3D1/+PROJ-PRDN-PROH-SDMB" ("= TODO" >>> "NEXT" "FXME" "STRT") nil ""))) >>> >> >> Here's what I did: >> >> I started Emacs with -Q, eval'ed the variables and custom agenda >> commands you sent set up the org-agenda-files and ran the custom >> commands `W' and `P'. =C2=A0Both listed all the items marked PROJ where >> they should have. =C2=A0So it worked for me.. I am not sure what could b= e >> wrong in your setup. =C2=A0I know it's a non-answer but FWIW, removing >> everything and add bits and pieces in steps could help. >> >> HTH >> -- >> Manish >> > > Thanks, Manish, > > I'll try that. Thanks a lot for your efforts! > > Best, > Christian > Update: I found the culprit in "org-enforce-todo-dependencies", set to nil and all projects labeled as PROJ are displayed again. Have to think about why this affects the agenda views in that way... thanks for listening, Christian