From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Kitchin Subject: Re: excluding whole trees on export when subtrees have "select" tags present Date: Tue, 10 Jan 2017 09:27:08 -0500 Message-ID: References: <878tqkmunb.fsf@ucl.ac.uk> <87a8azkioa.fsf@ucl.ac.uk> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:52197) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cQxOP-0004Uy-AT for emacs-orgmode@gnu.org; Tue, 10 Jan 2017 09:27:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cQxOL-0000yS-5Q for emacs-orgmode@gnu.org; Tue, 10 Jan 2017 09:27:17 -0500 Received: from mail-qt0-x232.google.com ([2607:f8b0:400d:c0d::232]:33521) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cQxOK-0000yM-W5 for emacs-orgmode@gnu.org; Tue, 10 Jan 2017 09:27:13 -0500 Received: by mail-qt0-x232.google.com with SMTP id v23so166504050qtb.0 for ; Tue, 10 Jan 2017 06:27:12 -0800 (PST) In-reply-to: <87a8azkioa.fsf@ucl.ac.uk> 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" To: Eric S Fraga Cc: emacs-orgmode@gnu.org This does not sound right to me. This org file: #+BEGIN_SRC org ,#+select_tags: wanted ,#+exclude_tags: notwanted ,* headline :notwanted: some text ,** subhead 1 ,** subhead2 :wanted: more text #+END_SRC should not have any thing to export. In contrast: #+BEGIN_SRC org ,#+select_tags: wanted ,#+exclude_tags: notwanted ,* headline :wanted: some text ,** subhead 1 ,** subhead2 :notwanted: more text #+END_SRC will export headline and subhead1. At least, that is what I see. Eric S Fraga writes: > On Monday, 9 Jan 2017 at 15:46, John Kitchin wrote: >> Based on the docstrings for org-export-select-tags and >> org-export-exclude-tags, this looks expected. >> >> It does not look possible to exclude a heading and include a subheading >> under it. It is possible to include a heading and exclude some >> subheadings though you need a wanted tag in the parent, and notwanted >> tags in the subtrees, and to declare the exclude tags. > > I think I was unclear. My confusion is that a tree (rooted at a top > level headline) that I do not want exported is nevertheless exported if > a subtree within that tree has a "selected" tag. I would have thought > the higher level heading would take precedence. > >> I am surprised you can use comment like this. It looks to me like >> commenting a tree makes all the subtrees in it not export too. > > Yes, it is. Again, I obviously didn't explain myself well. I have > resorted to commenting out whole trees (rooted at headlines) to avoid > them being exported because a sub-tree has the selected tag. > > In any case, I have found a workaround by inverting my tag usage. > > thanks, > eric -- Professor John Kitchin Doherty Hall A207F Department of Chemical Engineering Carnegie Mellon University Pittsburgh, PA 15213 412-268-7803 @johnkitchin http://kitchingroup.cheme.cmu.edu