From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Loury Subject: Re: Hiding "blocked" TODO items Date: Tue, 07 Apr 2015 09:33:49 +0200 Message-ID: <87384cpf36.fsf@konixwork.incubateur.ens-lyon.fr> References: <87twws8w3y.fsf@vostro.rath.org> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60744) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YfO1J-0003vp-Aj for emacs-orgmode@gnu.org; Tue, 07 Apr 2015 03:34:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YfO1E-0005dI-BI for emacs-orgmode@gnu.org; Tue, 07 Apr 2015 03:34:01 -0400 Received: from mail-wg0-x234.google.com ([2a00:1450:400c:c00::234]:35429) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YfO1E-0005d6-4z for emacs-orgmode@gnu.org; Tue, 07 Apr 2015 03:33:56 -0400 Received: by wgyo15 with SMTP id o15so35810273wgy.2 for ; Tue, 07 Apr 2015 00:33:54 -0700 (PDT) In-Reply-To: <87twws8w3y.fsf@vostro.rath.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Nikolaus Rath , emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Dear Nikolaus, Nikolaus Rath writes: > Is there a way to have TODO items "blocking" each other? > > For example, if I have this document: > > * TODO Pay water > :PROPERTIES: > :blocked-on: checks > :END: > * TODO Pay electricity > :PROPERTIES: > :blocked-on: checks > :END: > * TODO Get new checks > :PROPERTIES: > :id: checks > :END: > > Then I'd like the first two TODO items not to show up in the agenda > until the third one is DONE (but I don't much care if the items can be > manually switched to DONE or not). > > I looked at org-depend.el but as far as I can tell, it only allows to > set up chains of dependencies, i.e. I could have "Pay Water" and "Pay > electricity" in state NEXT, and have a trigger in "Get new checks" that > would switch one, but not both, of the NEXT items to TODO. > > Do I understand that correctly? Is there some other way to achieve what > I want? I think that the dependency could be declared using org-depend but with the BLOCKER keyword instead of the TRIGGER one. To allow the elements to still be set to DONE, you could use the NOBLOCKING keyword. Then, in the agenda view, you could use the org-agenda-skip-function variable and put something like org-depend-block-todo that would indicate to skip the blocked items. Sorry to be to lazy to write the code here... The outline would look like this: =2D-8<---------------cut here---------------start------------->8--- * TODO Pay water :PROPERTIES: :BLOCKER: checks :NOBLOCKING: t :END: * TODO Pay electricity :PROPERTIES: :BLOCKER: checks :NOBLOCKING: t :END: * TODO Get new checks :PROPERTIES: :id: checks :END: =2D-8<---------------cut here---------------end--------------->8--- Having at the same time BLOCKER and NOBLOCKING appears a bit confusing to me. May be it is not a so good solution and an org-mode guru will probably correct me :-). Hoping this was useful. Best regards, =2D-=20 Konubinix GPG Key : 7439106A Fingerprint: 5993 BE7A DA65 E2D9 06CE 5C36 75D2 3CED 7439 106A --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJVI4hdAAoJEHXSPO10ORBqeMoH/i86B4S+nKWAZo2SI8X5Lq+J hp/CDWwY4XDYv5WNUq5JQpomtKP5vCrDsK+ddXkuiZzFT0eBnB59KtGkA7JW2guG vjrY0RxCRSkMLzikh+SJ3pMMtUFWpxuMzxMt/wU3HpZyXBxVA/5XTxDPpdWplzN9 FHNHSa09mOM3L4fcuhc9ivgWtkOdPXLdiwblfcrfe3DayfPWejawMD9VIYt3yufU QzGRflwAFR6PDI3VxfHtXrKW8J2Y088LpEmoy2PbfG2qEA/aQmaQJ/pkX7Cw3QrK Df4k8tY/2p/GuKUFCd+tE+uF99mMzzBLs4KHqC3UromnVnwMykMO560rfhgYp94= =zsyd -----END PGP SIGNATURE----- --=-=-=--