From 58c42c3b2fc83f3541eecbf07ae8bebb42a0e962 Mon Sep 17 00:00:00 2001 From: Tony Stork Date: Wed, 12 Oct 2022 16:38:28 -0400 Subject: [PATCH] Changes for #50 --- packages/presence.yaml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/packages/presence.yaml b/packages/presence.yaml index 560490d..efdccdb 100644 --- a/packages/presence.yaml +++ b/packages/presence.yaml @@ -342,6 +342,28 @@ script: entity_id: input_select.dining_room_lamp_scenes data: option: Full + else: + - if: + - condition: template + value_template: > + {% set weather = states('weather.iron_nerd_weather_station') %} + {% if weather in ['cloudy','partlycloudy','rainy','snowy','hail','lightning','lightning-rainy','pouring','snowy-rainy'] %} + true + {% else %} + false + {% endif %} + - condition: not + conditions: + - condition: sun + after: sunset + after_offset: -00:30 + then: + - service: light.turn_on + target: + area_id: + - living_room + - dining_room + - mud_room - service: script.welcome_home mode: single icon: mdi:home-account \ No newline at end of file