From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Hendy Subject: Re: Automatic noexport tag based on rules? Date: Fri, 25 Feb 2011 16:37:13 -0600 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1729868031==" Return-path: Received: from [140.186.70.92] (port=60102 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pt6Hq-0000Jy-38 for emacs-orgmode@gnu.org; Fri, 25 Feb 2011 17:37:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pt6Hk-0003HW-VO for emacs-orgmode@gnu.org; Fri, 25 Feb 2011 17:37:22 -0500 Received: from mail-bw0-f41.google.com ([209.85.214.41]:64210) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pt6Hk-0003HP-MX for emacs-orgmode@gnu.org; Fri, 25 Feb 2011 17:37:16 -0500 Received: by bwz17 with SMTP id 17so2804841bwz.0 for ; Fri, 25 Feb 2011 14:37:15 -0800 (PST) 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: emacs-orgmode --===============1729868031== Content-Type: multipart/alternative; boundary=001636c5c272b3eb00049d22f8f9 --001636c5c272b3eb00049d22f8f9 Content-Type: text/plain; charset=ISO-8859-1 Reviving this as I can't believe the following solution was overlooked! On Tue, Feb 8, 2011 at 6:29 PM, John Hendy wrote: > Hi, > > > My apologies if this has been discussed. I couldn't find it. I write > everything from work in org-mode for several reasons. Primarily, it's my > documentation system for research in order to properly document Intellectual > Property (IP) information. It's also for todos and contacts. When it comes > to exporting my notes into PDF for use in an IP notebook... I dont' want my > todos in there. > > Is there a way to automatically tag TODOs with :noexport:? > > YES! While perusing Bernt Hanson's page ( http://doc.norang.ca/org-mode.html#ToDoStateTriggers) I noticed the following: ,----- | I have a few triggers that automatically assign tags to tasks based on | state changes. If a task moves to CANCELLED state then it gets a CANCELLED tag. | Moving a CANCELLED task back to TODO removes the CANCELLED tag. | These are used for filtering tasks in agenda views which I'll talk about later. | ... then he shows the code used to set =org-todo-state-tags-triggers= `----- Sweetness, I thought. In experimenting: ,----- | (setq org-todo-state-tags-triggers | (quote (("TODO" ("noexport" . t))))) `----- works *perfectly*. Well, that is in my 0.2 seconds of experimentation, it worked. New headline -> C-c C-t -> ** TODO whatever :noexport: I'm a happy camper. I had resolved to arranging my file with a separate =* Tasks= top level item at the top of each file to store all todos (I may still do this) and then I could just tag the whole headline with :noexport: to keep all the todos out of the export since I'm often typing notes or something and the TODO seems to fit better in the context of the notes rather than having to stuff it into a bucket at the top with TODOs from all kinds of other stuff.. At least if I don't do this, I have some options. Adding a todo in place will keep it from being exported when I print out my reports. The world is safe again... Best regards, John Or simply add the TODO category to the noexport category altogether? > > I haven't turned up anything quite along these lines. One post suggested > using "TODO keyword COMMENT" [1], but that just seems to perhaps exclude > from export (didn't try) but I know for sure it removes it from agenda view. > I want TODOs in agenda but don't want them showing up with my LaTeX export. > I typically print out my work to-date each month or so and have to comb > through my org file for that month, manually adding :noexport: to my TODOs. > Even if I still do this for a few things here and there... it will save me a > lot of time. > > I suppose I could keep a separate "TODO.org" file, but I really like the > process of being able to add them anywhere -- it seems more natural to do > that in the flow, particularly in meetings, than to constantly switch > buffers or even use remember to keep sending things related to the current > topic away to their own island. > > I'm 80% confident that the answer is ridiculously simply and I just haven't > searched the right thing. Thanks for enlightening me! > > > Thanks, > John > --001636c5c272b3eb00049d22f8f9 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Reviving this as I can't believe the following solution was overlo= oked!

On Tue, Feb 8, 2011 at 6:29 PM, J= ohn Hendy <jw.he= ndy@gmail.com> wrote:
Hi,


My ap= ologies if this has been discussed. I couldn't find it. I write everyth= ing from work in org-mode for several reasons. Primarily, it's my docum= entation system for research in order to properly document Intellectual Pro= perty (IP) information. It's also for todos and contacts. When it comes= to exporting my notes into PDF for use in an IP notebook... I dont' wa= nt my todos in there.

Is there a way to automatically tag TODOs with :noexpor= t:?


YES! While perusin= g Bernt Hanson's page (http://doc.norang.ca/org-mode.html#ToDoStateTriggers) = I noticed the following:
,-----
|=A0|=A0sta= te changes. If a task moves to=A0CA= NCELLED=A0state then it gets a=A0CANCELLED=A0tag.
|=A0Mov= ing a=A0CANCELLED=A0task bac= k to=A0TODO=A0removes the=A0= CANCELLED=A0tag. |=A0The= se are used for filtering tasks in agenda views which I'll talk about l= ater.
|= ... then he shows the code used to set =3Dorg-todo-state-tags-triggers=3D<= /div>
`-----=A0

Sweetness, I thought. In experiment= ing:
,-----
|=A0(setq org-todo-state-tags-triggers
| =A0 =A0 =A0(quote (("TODO" ("noexport" . t= )))))
`-----

works perfectly. Well, th= at is in my 0.2 seconds of experimentation, it worked. New headline -> C= -c C-t -> ** TODO whatever :noexport:

I'm a= happy camper. =A0I had resolved to arranging my file with a separate =3D* = Tasks=3D top level item at the top of each file to store all todos (I may s= till do this) and then I could just tag the whole headline with :noexport: = to keep all the todos out of the export since I'm often typing notes or= something and the TODO seems to fit better in the context of the notes rat= her than having to stuff it into a bucket at the top with TODOs from all ki= nds of other stuff.. At least if I don't do this, I have some options. = Adding a todo in place will keep it from being exported when I print out my= reports.

The world is safe again...

Best regards,
John

Or simply add the TODO category to the noexport category al= together?

I haven't turned up anything quite a= long these lines. One post suggested using "TODO keyword COMMENT"= [1], but that just seems to perhaps exclude from export (didn't try) b= ut I know for sure it removes it from agenda view. I want TODOs in agenda b= ut don't want them showing up with my LaTeX export. I typically print o= ut my work to-date each month or so and have to comb through my org file fo= r that month, manually adding :noexport: to my TODOs. Even if I still do th= is for a few things here and there... it will save me a lot of time.

I suppose I could keep a separate "TODO.org" = file, but I really like the process of being able to add them anywhere -- i= t seems more natural to do that in the flow, particularly in meetings, than= to constantly switch buffers or even use remember to keep sending things r= elated to the current topic away to their own island.

I'm 80% confident that the answer is ridiculously s= imply and I just haven't searched the right thing. Thanks for enlighten= ing me!


Thanks,
John

--001636c5c272b3eb00049d22f8f9-- --===============1729868031== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============1729868031==--