I wrote a script to compile and format *.yaml.jinja templates in my Home Assistant config directory

I posted this as a feature request: Support for jinja templates in homeassistant.yaml configuration files

Then I ended up writing a script for myself. It’s pretty cool and turned out way better than I expected! Now I can actually see the compiled YAML and view it side-by-side. I also print any errors to a log file so I can see how to fix any issues.

You can see a demo video here: Demo: Jinja templates for Home Assistant configuration - YouTube

I put the script / service in a GitHub gist: Script to compile and format *.yaml.jinja files in Home Assistant config directory (Including systemd service) · GitHub

2 Likes