From 003fe98ecf193ade396267ac4385447a7e8f1b7c Mon Sep 17 00:00:00 2001 From: "J.P. Krauss" Date: Sat, 26 Nov 2022 16:45:31 -0800 Subject: [PATCH] Fix Holiday Automations --- packages/holiday/holiday.yaml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/holiday/holiday.yaml b/packages/holiday/holiday.yaml index 9857d14..9ae537f 100644 --- a/packages/holiday/holiday.yaml +++ b/packages/holiday/holiday.yaml @@ -19,9 +19,10 @@ automation: trigger: - platform: sun event: sunset - # TODO: Add Conditions + condition: + - "{{ is_state('binary_sensor.is_christmas_season', 'on') }}" action: - - service: light.turn_on + - service: switch.turn_on target: entity_id: switch.christmas_lights_front @@ -29,9 +30,10 @@ automation: trigger: - platform: time at: '04:30:00' - # TODO: Add Conditions + condition: + - "{{ is_state('binary_sensor.is_christmas_season', 'on') }}" action: - - service: light.turn_on + - service: switch.turn_on target: entity_id: switch.christmas_lights_front @@ -39,9 +41,8 @@ automation: trigger: - platform: time at: '00:00:00' - # TODO: Add Conditions action: - - service: light.turn_off + - service: switch.turn_off target: entity_id: switch.christmas_lights_front @@ -50,8 +51,7 @@ automation: - platform: sun event: sunrise offset: '-00:30:00' - # TODO: Add Conditions action: - - service: light.turn_off + - service: switch.turn_off target: entity_id: switch.christmas_lights_front