I am looking for a way to get the time one hour before sunset. My goal is to see if the the current time is between sunset - 1 hr and sunset. For the sake of readability, I want to avoid templating as much as possible. Simply put, I want it to look something like this, if possible:
- condition: time
after: sensor.sun_next_setting - 1hr
before: sensor.sun_next_dusk
Is there a way to create a helper for example to give me the time for that day sunset - 1hr?
9 posts - 3 participants