TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Show HN: Makejinja: Automatically generate complex Home Assistant configurations

14 点作者 mlenz超过 2 年前
makejinja can be used to automatically generate files from Jinja templates. This allows you to load variables from external files or create repeating patterns via loops. A very interesting use case for this tool is generating config files for Home Assistant: Using the same language that the built-in templates use, you can greatly simplify your configuration. When creating for example dashboards, it allows you to create a view for each room based on a single common template, dramatically reducing the maintenance overhead of complex dashboards. I originally developed this for my smarthome setup, but thought it may be useful for others as well!<p>A concrete example for Home Assistant can be found in the tests directory: <a href="https:&#x2F;&#x2F;github.com&#x2F;mirkolenz&#x2F;makejinja&#x2F;blob&#x2F;main&#x2F;tests&#x2F;data">https:&#x2F;&#x2F;github.com&#x2F;mirkolenz&#x2F;makejinja&#x2F;blob&#x2F;main&#x2F;tests&#x2F;data</a><p>For more information like detailed features or installation&#x2F;usage instructions, please visit the GitHub repo.

2 条评论

kkfx超过 2 年前
I always ask myself anytime I have to deal with my HA or k8s stuff why the hell people want to shot themselves in the genitals with YAML crap instead of using a damn programming language for a damn personal config.
评论 #34646691 未加载
评论 #34646658 未加载
MattDemers超过 2 年前
Happy to see this, mostly because HomeAssistant stuff is nowhere near consumer-ready. I barely have the Docker knowledge to get it working in the first place on my NAS, and even just doing basic automations assumes you know much more coding&#x2F;process stuff than the typical normie.
评论 #34646790 未加载
评论 #34649781 未加载
评论 #34646719 未加载