jinja2-cli

Render Jinja2 templates from the command line with JSON or YAML data

brewmacoslinux
Try with needOr install directly
Source

About

CLI for the Jinja2 templating language

Commands

jinja2

Examples

fill in template variables from a JSON file$ jinja2 template.j2 data.json
render template with inline JSON data$ jinja2 template.j2 -d '{"name": "Alice", "age": 30}'
process YAML configuration into text output$ jinja2 config.j2 values.yaml
loop through list items in template$ jinja2 list_template.j2 -d '{"items": ["one", "two", "three"]}'
generate file from template with environment variables$ jinja2 dockerfile.j2 -e | docker build -f - .