mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-18 23:06:58 +00:00
Add description for removing holidays by name (#18423)
This commit is contained in:
parent
dca72d1f4f
commit
8a00a52b87
@ -66,7 +66,7 @@ add_holidays:
|
||||
required: false
|
||||
type: list
|
||||
remove_holidays:
|
||||
description: "Remove holidays (treat holiday as workday). Needs to formatted as `YYYY-MM-DD`."
|
||||
description: "Remove holidays (treat holiday as workday). Can be formatted as `YYYY-MM-DD` or by name for a partial string match (e.g. Thanksgiving)."
|
||||
required: false
|
||||
type: list
|
||||
{% endconfiguration %}
|
||||
@ -127,6 +127,20 @@ binary_sensor:
|
||||
- '2020-12-25'
|
||||
```
|
||||
|
||||
This example excludes Saturdays, Sundays and holidays. Two holidays are removed by name: Thanksgiving and Christmas Day.
|
||||
|
||||
```yaml
|
||||
# Example 4 configuration.yaml entry
|
||||
binary_sensor:
|
||||
- platform: workday
|
||||
country: US
|
||||
workdays: [mon, tue, wed, thu, fri]
|
||||
excludes: [sat, sun, holiday]
|
||||
remove_holidays:
|
||||
- 'Thanksgiving'
|
||||
- 'Christmas Day'
|
||||
```
|
||||
|
||||
## Automation example
|
||||
|
||||
Example usage for automation:
|
||||
|
Loading…
x
Reference in New Issue
Block a user