mirror of
https://github.com/CeeWeasel/fresh-home.git
synced 2026-08-09 18:40:14 -04:00
initial push
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
alias: New Mail
|
||||
id: automation_new_mail
|
||||
|
||||
# Removed 'No Mail' trigger and action because mail should only be considered "checked" once the boolean has been turned off
|
||||
|
||||
trigger:
|
||||
- id: new_mail
|
||||
platform: numeric_state
|
||||
entity_id: sensor.mail_usps_mail
|
||||
above: 0
|
||||
|
||||
- id: no_mail
|
||||
platform: numeric_state
|
||||
entity_id: sensor.mail_usps_mail
|
||||
below: 1
|
||||
|
||||
- platform: homeassistant
|
||||
event: start
|
||||
|
||||
- platform: event
|
||||
event_type: automation_reloaded
|
||||
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: numeric_state
|
||||
entity_id: sensor.mail_usps_mail
|
||||
above: 0
|
||||
|
||||
sequence:
|
||||
- service: input_boolean.turn_on
|
||||
target:
|
||||
entity_id: input_boolean.incoming_mail
|
||||
|
||||
- conditions:
|
||||
- condition: numeric_state
|
||||
entity_id: sensor.mail_usps_mail
|
||||
below: 1
|
||||
|
||||
sequence:
|
||||
- service: input_boolean.turn_off
|
||||
target:
|
||||
entity_id: input_boolean.incoming_mail
|
||||
|
||||
|
||||
Reference in New Issue
Block a user