Framework for writing reactive-style Juju Charms
Project description
charms.templating.jinja2
Helper for rendering Jinja2 templates with charms
Usage
from charms.templating.jinja2 import render
render('app.conf.j2', '/etc/app.conf', {
'my_var': 'my_val',
})
output = render(
'tmpl.j2',
tests={
'isnumeric': lambda s: s.isnumeric(),
})
output = render(
template='{{ config["my-opt"]|my_upper }}',
filters={
'my_upper': lambda s: s.upper(),
})
The full documentation is available at http://pythonhosted.org/charms.templating.jinja2/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Close
Hashes for charms.templating.jinja2-1.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 463de79519b7e27198303abc66b11710934a9691e1e61c20853f69662c63e39d |
|
MD5 | e7b0b356ed42c858ed89a280bc39cb42 |
|
BLAKE2b-256 | 5564ab6d9de77753560ad62179a5e5eb77ecd6ccff206dca5e419a2b05bf6d41 |