Disclaimer: I am posting this here mainly because I saw discussions about this in the community here far too often and I want a topic to reference people to.
Disclaimer 2: This suggestion does not stand in conflict with the new concept of labels etc but rather works in parallel. It would be amazing if a future improvement merges the concept of packages and labels.
Feature Request:
Please consider adding an included packages folder to the default yaml configuration for new setups.
Implications:
- New users relying on the UI to configure their setup will not be harmed by it
- Users comfortable to work in yaml will benefit from this addition as a feature they may but do not have to use.
It should also be considered that many snippets here in the community assume a packages based setup and users are regularly confused by that.
Justification and implementation today:
A quickly growing yaml-based configuration can become confusing and hard to maintain. It is, therefore, useful to follow a use-case driven approach by structuring your configuration by topics like heating, night-light or garage-door-automation. These “packages” are independent files and make management and troubleshooting a lot simpler. This approach can nowadays also be found in the UI configuration with “labels”.
In short, enable packages in your <HomeAssistantConfig>/configuration.yaml
like this:
homeassistant:
packages: !include_dir_named packages
Then move your topic specific configuration elements into files like <HomeAssistantConfig>/packages/heating-or-something.yaml
The file configuration.yaml
will stay unchanged going forward.
More details on packages: