Quantcast
Channel: Active questions tagged org-mode - Emacs Stack Exchange
Viewing all articles
Browse latest Browse all 313

org-mode: per-exporter #+SELECT_TAGS & #+EXCLUDE_TAGS?

$
0
0

Problem statement

In Emacs org-mode, I am looking for a way to define #+EXPORT_EXCLUDE_TAGS (which defaults to :noexport) and #+EXPORT_SELECT_TAGSon a per-exporter basis, such that they apply only to specific exporters.

However, as far as I know, this functionality, which is detailed in the answer to this related question, applies globally to all org-mode exporters.

Background

This problem arises from my desire to use the same org-mode source code to export to both,

  1. regular HTML (for a verbose 'textbook-style' document), and
  2. a Reveal.js presentation (which should be less verbose by excluding accordingly tagged sections). NB: For this I use org-re-reveal, but my question is more generically about "different exporters" (could also concern HTML vs. LaTeX export, for example).

Essentially, I am trying to mimic LaTeX Beamer's "article mode", which allows the use of markers such as \only<article>, \mode<presentation>, \mode<all>, etc. to make certain content only appear in specific documents, all of which are compiled from the same source.

What I imagine a solution to look like

My idea is to have org-mode code like the following:

* Some section** Subsection content shows up in HTML, but not Reveal.js   :html:ignore:- Foo- Bla** Subsection content shows up in Reveal.js, but not HTML   :reveal:ignore:1. More2. lists** Subsection content shows up in both, HTML and Reveal.js  :reveal:html:ignore:- Some- text

This would require defining the tags :html and :reveal as exporter-specific#+EXPORT_SELECT_TAGS, but I don't know whether/how this is possible.

NB: The :ignore tag serves the purpose of excluding the subsection headings themselves in the export, whose sole purpose should be to control what is exported where. Of course if would be nice to include that functionality, too, in the definition of the :html and :reveal tags.


Viewing all articles
Browse latest Browse all 313

Latest Images

Trending Articles





Latest Images