mirror of
https://github.com/CeeWeasel/fresh-home.git
synced 2026-08-09 18:40:14 -04:00
19 lines
856 B
YAML
19 lines
856 B
YAML
alias: 'Season is Christmas'
|
|
id: automation_season_is_christmas
|
|
initial_state: 'on'
|
|
trigger:
|
|
- platform: homeassistant
|
|
event: start
|
|
- platform: time
|
|
at: '02:00:00'
|
|
condition:
|
|
- condition: template
|
|
#value_template: '{{ ( now().month == 12 and now().day >= 1 ) and ( now().month == 12 and now().day < 31 ) }}'
|
|
#value_template: "{{ state_attr('calendar.holidays_in_united_states','message') == 'Christmas Eve' or state_attr('calendar.holidays_in_united_states','message') == 'Christmas Day' or state_attr('calendar.holidays_in_united_states','message') == 'New Year''s Eve'}}"
|
|
value_template: "{{ state_attr('calendar.holidays_in_united_states', 'message') in 'Christmas Eve' 'Christmas Day' 'New Year''s Eve' }}"
|
|
action:
|
|
- service: input_select.select_option
|
|
data:
|
|
entity_id: input_select.season
|
|
option: Christmas
|