git.iko.soy/typeable/pandoc
on master help sign in
customizing-templates.md: variable options table
0466c0aMauro Bieg
doc/customizing-pandoc.md+21−2
@@ -39,8 +39,27 @@ or by putting the custom template in your user data directory
39(on linux and macOS, `~/.pandoc/templates/`).
39(on linux and macOS, `~/.pandoc/templates/`).
40
40
41Note that in many cases you can avoid the need for a custom
41Note that in many cases you can avoid the need for a custom
42−template by making use of the `--include-in-header`,
42+template by including a file with the `--include-in-header`,
43−`--include-before-body`, and `--include-after-body` options.
43+`--include-before-body`, or `--include-after-body` option.
44+Or you can set the corresponding template variable directly.
45+
46+### Template variables
47+
48+There are several ways to set template variables:
49+
50+| | [`--variable`] | [`--metadata`] | [YAML metadata] and [`--metadata-file`] |
51+|:---------------|:------------------|:------------------|:----------------------------|
52+| values can be… | strings and bools | strings and bools | also YAML objects and lists |
53+| strings are… | inserted verbatim | escaped | interpreted as markdown |
54+| accessible by filters: | no | yes | yes |
55+
56+
57+[`--variable`]: http://pandoc.org/MANUAL.html#option--variable
58+[`--metadata`]: http://pandoc.org/MANUAL.html#option--metadata
59+[YAML metadata]: http://pandoc.org/MANUAL.html#extension-yaml_metadata_block
60+[`--metadata-file`]: http://pandoc.org/MANUAL.html#option--metadata-file
61+
62+
44
63
45For more information, see [Templates](/MANUAL.html#templates) in
64For more information, see [Templates](/MANUAL.html#templates) in
46the pandoc manual.
65the pandoc manual.