Skip to main content

Plugin which provides TOML format (data input) support for jinjanator

Project description

jinjanator-plugin-format-toml: Provides TOML format (data input) support for jinjanator

This plugin allows jinjanator to parse TOML data for processing in templates. The format can be selected using --format toml or autoselected by using a data file with a name ending with .toml.

Installation

pip install jinjanator-plugin-format-toml

Usage

Suppose you have an NGINX configuration file template, nginx.j2:

server {
  listen 80;
  server_name {{ nginx.hostname }};

  root {{ nginx.webroot }};
  index index.htm;
}

And you have a TOML file with the data, nginx.toml:

[nginx]
hostname="localhost"
webroot="/var/www/project"

This is how you render it into a working configuration file:

$ jinjanate nginx.j2 nginx.toml > nginx.conf

Options

This format does not support any options.

Release Information

Changes

  • Upgraded to version 24.1 of jinjanator-plugins.

→ Full Changelog

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jinjanator_plugin_format_toml-24.1.0.tar.gz (8.9 kB view hashes)

Uploaded Source

Built Distribution

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page