1
0
Fork 0
mirror of synced 2024-11-13 21:18:57 -05:00

Add documentation for the template include directive

This commit is contained in:
Erik Flodin 2020-10-10 21:18:16 +02:00
parent f2a69735b4
commit c0b2fd2ab7
No known key found for this signature in database
GPG key ID: 420A7C865EE3F85F

View file

@ -106,6 +106,17 @@ This block is included for any other OS
{% endif %}
```
include
: Content can be included from external files using the
`{% include "filename" %}` syntax. The filename may include variables and
should be either a path relative to the current template or an absolute
path. The included file may itself also use variables, but if-else-endif or
include directives are not supported. An example:
```jinja
{% include "extra/config.{{ yadm.os }}" %}
```
{% endraw %}
[envtpl]: https://github.com/andreasjansson/envtpl