mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-19 15:26:59 +00:00
Added include and exclude functionality to history component (#1094)
* Added lgtv platform to control a LG Smart TV running NetCast 3.0 (LG Smart TV models released in 2012) and NetCast 4.0 (LG Smart TV models released in 2013). * Update media_player.lgtv.markdown * Rename media_player.lgtv.markdown to media_player.lg_netcast.markdown * added description of the include/exclude entities/domains feature for history component. * o moved configuration examples to the section where the filtering is explained o improved configuration variables description
This commit is contained in:
parent
1a9b9ebc0d
commit
256fb8ba05
@ -18,7 +18,7 @@ The `history` component will track everything that is going on within Home Assis
|
||||
To enable the history option in your installation, add the following to your `configuration.yaml` file:
|
||||
|
||||
```yaml
|
||||
# Example configuration.yaml entry
|
||||
# Basic configuration.yaml entry
|
||||
history:
|
||||
```
|
||||
|
||||
@ -32,6 +32,56 @@ history:
|
||||
Events are saved in a local database. Google Graphs is used to draw the graph. Drawing is happening 100% in your browser. No data is transferred to anyone at any time.
|
||||
</p>
|
||||
|
||||
|
||||
Configuration variables:
|
||||
|
||||
- **exclude** (*Optional*): Configure which components should **not** be displayed.
|
||||
- **entities** (*Optional*): The list of entity ids to be excluded from the history.
|
||||
- **domains** (*Optional*): The list of domains to be excluded from the history.
|
||||
- **include** (*Optional*): Configure which components should be displayed.
|
||||
- **entities** (*Optional*): The list of entity ids to be included from the history.
|
||||
- **domains** (*Optional*): The list of domains to be included from the history.
|
||||
|
||||
Without any `include` or `exclude` configuration the history displays graphs for every entity (well that's not exactly true - for instance `hidden` entities or `scenes` are never shown) on a given date. If you are only interested in some of the entities you several options:
|
||||
|
||||
- Define domains and entities to `exclude` (aka. blacklist). This is convenient when you are basically happy with the information displayed, but just want to remove some entities or domains. Usually these are entities/domains which do not change (like `weblink`) or rarely change (`updater` or `automation`).
|
||||
```yaml
|
||||
# Example configuration.yaml entry with exclude
|
||||
history:
|
||||
exclude:
|
||||
domains:
|
||||
- automation
|
||||
- weblink
|
||||
- updater
|
||||
entities:
|
||||
- sensor.last_boot
|
||||
- sensor.date
|
||||
```
|
||||
- Define domains and entities to display by using the `include` configuration (aka. whitelist). If you have a lot of entities in your system and your `exclude` lists possibly get very large, it might be better just to define the entities or domains to display.
|
||||
```yaml
|
||||
# Example configuration.yaml entry with include
|
||||
history:
|
||||
include:
|
||||
domains:
|
||||
- sensor
|
||||
- switch
|
||||
- media_player
|
||||
```
|
||||
- Use the `include` list to define the domains/entities to display, and exclude some of them with in the `exclude` list. This makes sense if you for instance include the `sensor` domain, but want to exclude some specific sensors. Instead of adding every sensor entity to the `include` `entities` list just include the `sensor` domain and exclude the sensor entities you are not interested in.
|
||||
```yaml
|
||||
# Example configuration.yaml entry with include and exclude
|
||||
history:
|
||||
include:
|
||||
domains:
|
||||
- sensor
|
||||
- switch
|
||||
- media_player
|
||||
exclude:
|
||||
entities:
|
||||
- sensor.last_boot
|
||||
- sensor.date
|
||||
```
|
||||
|
||||
#### {% linkable_title Implementation details %}
|
||||
|
||||
The history is stored in a SQLite database `home-assistant.db` within your config directory.
|
||||
|
Loading…
x
Reference in New Issue
Block a user