From: "Clément Pit--Claudel" <clement.pit@gmail.com>
To: Kaushal Modi <kaushal.modi@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Restrict include to some backend
Date: Wed, 14 Sep 2016 08:21:36 -0400 [thread overview]
Message-ID: <b4262280-45cd-8738-0f67-eadcf0a19230@gmail.com> (raw)
In-Reply-To: <CAFyQvY0LUfsFSad4UJPRMvsmJZzisuALUOrnfDiZ7_PELq24gA@mail.gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 1248 bytes --]
On 2016-09-14 07:55, Kaushal Modi wrote:
> On Mon, Sep 12, 2016 at 11:14 PM Clément Pit--Claudel <clement.pit@gmail.com <mailto:clement.pit@gmail.com>> wrote:
>
> Sure thing :) Here it is:
>
>
> Thanks! This works great! I added it to `org-export-before-processing-hook'.
Glad to hear that :)
> I did not understand why you mentioned: "I call this before calling `org-latex-export-to-latex'.".
Back when I wrote this I was starting out with Org-mode, I was in a hurry, and I didn't know about org-export-before-processing-hook :) So instead I had a larger ELisp script that opened the file, ran this filter, then called org-latex-export-to-latex :)
> I plan to add a "not" condition to this. That way, with below:
>
> #+BEGIN_ONLY tex
> foo
> #+END_ONLY tex
>
> #+BEGIN_EXCEPT tex
> bar
> #+END_EXCEPT tex
>
> foo will be exported only for tex, and for every other backend, bar will be exported.
>
> WDYT?
Looks good. Maybe using the same syntax for both would be good though; something like "BEGIN_ONLY tex" and "BEGIN_ONLY :not tex" maybe?
We could probably get rid of the "tex" part after the END_ONLY, and change "tex" to "latex" for consistency with BEGIN_EXPORT :)
Cheers,
Clément.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-09-14 12:22 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-06 5:13 Restrict include to some backend Fabrice Popineau
2016-09-06 13:59 ` Clément Pit--Claudel
2016-09-06 14:59 ` Clément Pit--Claudel
2016-09-06 15:58 ` Nicolas Goaziou
2016-09-06 18:15 ` Clément Pit--Claudel
2016-09-06 20:32 ` Nicolas Goaziou
2016-09-13 3:10 ` Kaushal Modi
2016-09-13 3:14 ` Clément Pit--Claudel
2016-09-14 11:55 ` Kaushal Modi
2016-09-14 12:21 ` Clément Pit--Claudel [this message]
2016-09-14 12:33 ` Kaushal Modi
2016-09-06 20:10 ` Fabrice Popineau
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=b4262280-45cd-8738-0f67-eadcf0a19230@gmail.com \
--to=clement.pit@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=kaushal.modi@gmail.com \
/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).