Packages: replace component by integration (#27776)

This commit is contained in:
c0ffeeca7 2023-06-13 11:02:14 +02:00 committed by GitHub
parent 2471304a5d
commit 45ca65d9d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,7 +3,7 @@ title: "Packages"
description: "Describes all there is to know about configuration packages in Home Assistant."
---
Packages in Home Assistant provide a way to bundle different component's configuration together. With packages we have a way to include different components, or different configuration parts using any of the `!include` directives introduced in [splitting the configuration](/docs/configuration/splitting_configuration).
Packages in Home Assistant provide a way to bundle different integration's configuration together. With packages we have a way to include different integrations, or different configuration parts using any of the `!include` directives introduced in [splitting the configuration](/docs/configuration/splitting_configuration).
Packages are configured under the core `homeassistant/packages` in the configuration and take the format of a package name (no spaces, all lower case) followed by a dictionary with the package configuration. For example, package `pack_1` would be created as:
@ -57,7 +57,7 @@ light:
There are some rules for packages that will be merged:
1. Platform based integrations (`light`, `switch`, etc) can always be merged.
2. Components where entities are identified by a key that will represent the entity_id (`{key: config}`) need to have unique 'keys' between packages and the main configuration file.
2. Integrations where entities are identified by a key that will represent the entity_id (`{key: config}`) need to have unique 'keys' between packages and the main configuration file.
For example if we have the following in the main configuration. You are not allowed to re-use "my_input" again for `input_boolean` in a package:
@ -69,7 +69,7 @@ There are some rules for packages that will be merged:
3. Any integration that is not a platform [1], or dictionaries with Entity ID keys [2] can only be merged if its keys, except those for lists, are solely defined once.
<div class='note tip'>
Components inside packages can only specify platform entries using configuration style 1, where all the platforms are grouped under the integration name.
Integrations inside packages can only specify platform entries using configuration style 1, where all the platforms are grouped under the integration name.
</div>
## Create a packages folder