emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
To: emacs-orgmode-mXXj517/zsQ@public.gmane.org
Subject: Re: Spurious exporting of text before first header
Date: Wed, 25 Sep 2013 09:34:52 +0200	[thread overview]
Message-ID: <86mwn12w2r.fsf@somewhere.org> (raw)
In-Reply-To: 86mwn1a6xn.fsf@iro.umontreal.ca

Hi François,

François Pinard wrote:
> This is an old annoyance of the Org exporter, yet I'm not sure what
> would be its best resolution.
>
> Whenever I use :export: tags on headers within an Org file, I expect
> only those headers and their contents to be exported (to HTML in my
> case), and almost nothing else, which I then consider private.
>
> However, if I have text and other contents prior to the first header of
> a file, those contents are indeed exported, while I would prefer not.
>
> Of course, #+TITLE and some other directives prior to the first header
> should be honored for their effect.  One might surely debate on the best
> way to handle #+INCLUDE directive.
>
> I wish the above comments might generate either a correction in Org, or
> an advice for me! :-)
>
> P.S. Some might suggest me that I avoid text prior to the first header.
> Surely, I have hundreds of Org files and for them all, have some
> personal conventions for their format and structure.  For regularity
> reasons, I would much like to continue having private initial text.

If you like text without initial heading in the exported file, but don't mind
adding an heading in the Org buffer, you could add this:

--8<---------------cut here---------------start------------->8---
* Initial text                             :ignoreheading:
--8<---------------cut here---------------end--------------->8---

and get what you want in the exported file.

I thought that the filter to ignore the heading only was already in Org, but a
quick test with the ASCII backend makes me thing it isn't. Anyway, you can find
recent posts on this.

Best regards,
  Seb

-- 
Sebastien Vauban

  reply	other threads:[~2013-09-25  7:34 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-25  3:58 Spurious exporting of text before first header François Pinard
2013-09-25  7:34 ` Sebastien Vauban [this message]
2013-09-25 15:03   ` François Pinard
2013-09-25 17:25     ` Nicolas Goaziou
2013-09-25 19:09       ` François Pinard
2013-09-26 11:26         ` Nicolas Goaziou
2013-09-26 11:38           ` Sebastien Vauban
2013-09-26 14:36             ` Nicolas Goaziou
2013-09-26 14:44               ` Sebastien Vauban
2013-09-26 15:15                 ` Nicolas Goaziou
2013-09-26 17:57                   ` Sebastien Vauban
2013-09-26 20:46           ` Carsten Dominik
2013-09-26  8:53       ` Marcin Borkowski
2013-09-25 19:05   ` François Pinard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86mwn12w2r.fsf@somewhere.org \
    --to=sva-news-d0wtavr13harg/idocfnwg@public.gmane.org \
    --cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).