Export options can be set: globally with variables; for an individual file by
making variables buffer-local with in-buffer settings (see In-buffer settings), by setting individual keywords, or by specifying them in a
compact form with the
#+OPTIONS keyword; or for a tree by setting
properties (see Properties and columns). Options set at a specific level
override options set at a more general level.
In-buffer settings may appear anywhere in the file, either directly or
indirectly through a file included using ‘#+SETUPFILE: filename or URL’
syntax. Option keyword sets tailored to a particular back-end can be
inserted from the export dispatcher (see The export dispatcher) using the
Insert template command by pressing #. To insert keywords
individually, a good way to make sure the keyword is correct is to type
#+ and then to use M-<TAB>1 for completion.
The export keywords available for every back-end, and their equivalent global variables, include:
org-export-default-language). With ‘#+LANGUAGE: fr’, for example, Org translates Table of contents to the French Table des matières.
:export:. When a tree is tagged with
org-export-select-tags), Org selects that tree and its sub-trees for export. Org excludes trees with
:noexport:tags, see below. When selectively exporting files with
:export:tags set, Org does not export any text that appears before the first headline.
:noexport:. When a tree is tagged with
org-export-exclude-tags), Org excludes that tree and its sub-trees from export. Entries tagged with
:noexport:will be unconditionally excluded from the export, even if they have an
:export:tag. Even if a sub-tree is not exported, Org will execute any code blocks contained in them.
#+OPTIONS keyword is a compact form. To configure multiple
options, use several
#+OPTIONS recognizes the
org-export-with-smart-quotes). Depending on the language used, when activated, Org treats pairs of double quotes as primary quotes, pairs of single quotes as secondary quotes, and single quote marks as apostrophes.
headline, the export process skips the contents and processes only the headlines (
mark, Org clearly marks the problem link in the output (
org-export-headline-levels). Below that level, headlines are treated differently. In most back-ends, they become list items.
org-export-with-section-numbers). When set to number ‘n’, Org numbers only those headlines at level ‘n’ or above. Setting
UNNUMBEREDproperty to non-
nildisables numbering of a heading. Since subheadings inherit from this property, it affects their numbering, too.
org-export-with-planning). “Planning information” comes from lines located right after the headline and contain any combination of these cookies:
nilto remove all tasks; or
todoto remove DONE tasks; or list the keywords to keep (
nildoes not export;
verbatimkeeps everything in verbatim (
When exporting sub-trees, special node properties in them can override the above keywords. They are special because they have an ‘EXPORT_’ prefix. For example, ‘DATE’ and ‘EXPORT_FILE_NAME’ keywords become, respectively, ‘EXPORT_DATE’ and ‘EXPORT_FILE_NAME’. Except for ‘SETUPFILE’, all other keywords listed above have an ‘EXPORT_’ equivalent.
org-export-allow-bind-keywords is non-
nil, Emacs variables
can become buffer-local during export by using the BIND keyword. Its syntax
is ‘#+BIND: variable value’. This is particularly useful for in-buffer
settings that cannot be changed using keywords.