Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- coffeedone:
- sequence:
- - service: light.turn_off
- data:
- entity_id: light.kaffe
- - service: light.turn_on
- data:
- entity_id: light.kitchen_sink,light.kitchen_sink_two #dim lights
- brightness: 127
- - delay: 00:00:01
- - service: media_player.turn_on
- data:
- entity_id: media_player.kitchen
- - service: media_player.volume_set
- data:
- entity_id: media_player.kitchen
- data_template:
- volume_level: >
- {% set map = {'Midnight': 0.35, 'Afternoon': 0.5} %}
- {{ map.get(states('sensor.part_of_day'), 0.45) }}
- - service: tts.amazon_polly_say #google_say
- data_template:
- entity_id: media_player.kitchen
- message: >
- {% if now().strftime("%H")|int < 12 %}
- {{["Caution hot coffee",
- "The only thing i know for sure about today is coffee. Everything else is just wild speculations.",
- "Life is scary without coffee.",
- "Once you wake up and smell the coffee, it’s hard to go back to sleep.",
- "Even bad coffee is better than no coffee at all.",
- "nothing make sense before coffee",
- "Time fore awesomeness",
- "Coffee is the best thing to douse the sunrise with.",
- "Doctors found traces of blood in my coffee stream."
- ] | random}} ...
- {% elif now().strftime("%H")|int < 18 %}
- {{["It's coffee o clock",
- "The only good substitute for a coffee is two coffees.",
- "My only plan today is coffee.",
- "Caffeine rules.",
- "Everyone should believe in something. I believe I will have another coffee.",
- "Caffeine — It maintains my sunny personality.",
- "Coffee smells like freshly ground heaven."
- ] | random}} ...
- {% elif now().strftime("%H")|int < 07 %}
- {{["Any time is coffee time.",
- "Never forget coffee.",
- "Get more out of life with coffee.",
- "Here you go. Grab your coffee",
- "Never Underestimate the Importance of Being Properly Caffeinated.",
- "Good Coffee – Cheaper than Prozac!",
- "People say money can’t buy happiness. They Lie. Money buys Coffee, Coffee makes Me Happy!",
- "Decaffeinated coffee is like a hairless cat, it exists, but that doesn’t make it right.",
- "Sometimes I stay up so late that I have my morning coffee before I go to bed."
- ] | random}} ...
- {% else %}
- {{["Any time is coffee time.",
- "Never forget coffee.",
- "Get more out of life with coffee.",
- "Here you go. Grab your coffee",
- "Never Underestimate the Importance of Being Properly Caffeinated.",
- "Good Coffee – Cheaper than Prozac!",
- "People say money can’t buy happiness. They Lie. Money buys Coffee, Coffee makes Me Happy!",
- "Decaffeinated coffee is like a hairless cat, it exists, but that doesn’t make it right.",
- "Sometimes I stay up so late that I have my morning coffee before I go to bed."
- ] | random}} ...
- {% endif %}
- {{ speech_message | replace("\n","") | replace(" ","") | replace(" "," ") }}
- - delay: 00:00:45
- - service: media_player.volume_set
- data:
- entity_id: media_player.kitchen
- data_template:
- volume_level: 0.4
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement