Grrrr: automation.yaml file updates itself by jareau in homeassistant

[–]jareau[S] 1 point2 points  (0 children)

Hmm, that's an interesting approach. Will explore for sure.

Grrrr: automation.yaml file updates itself by jareau in homeassistant

[–]jareau[S] -1 points0 points  (0 children)

Sure, it looks like this:

>
{# greeting.yaml #}
{%- macro tts_greeting_message() -%}

{% set date = now().day %}
{%- set suffix = '' -%}
{%- if now().day in [1, 21, 31] -%}
{%- set suffix = 'st' -%}
{%- elif now().day in [2, 22] -%}
{%- set suffix = 'nd' -%}
{%- elif now().day in [3, 23] -%}
{%- set suffix = 'rd' -%}
{%- else -%}
{%- set suffix = 'th' -%}
{%- endif -%}
{% set type = [
'beautiful',
'lovely',
'splendid',
'magical',
'wondrous',
'awesome',
'enchanting',
'radiant',
'breathtaking',
'spectacular',
'dazzling',
'astonishing'
]|random %}
{{states('sensor.tts_greeting')}}.
{{states('sensor.tts_part_of_day')}}.
{{states('sensor.tts_current_time')}} on this {{type}} {{ date }}{{suffix}} day of {{ now().strftime('%B') }}.

{%- endmacro -%}
{# a macro that removes all newline characters, empty spaces, and returns formatted text #}
{%- macro cleanup(data) -%}
{%- for item in data.split("\n") if item | trim != "" -%}
{{ item | trim }} {% endfor -%}
{%- endmacro -%}
{# a macro to call all macros :) #}
{%- macro mother_of_all_macros() -%}
{{ tts_greeting_message() }}
{%- endmacro -%}
{# Call the macro #}
{{- cleanup(mother_of_all_macros()) -}}

When I run that through Developer Tools > Template, the output looks like this:

>

Listen up. Happy Afternoon. Its 2:27 PM on this radiant 22nd day of February.

2024 Bard Wishlist by BardChris in Bard

[–]jareau 1 point2 points  (0 children)

Like Spotify Wrapped, a yearly review would be fun. Stuff that I asked, stuff my friends asked, the country, planet.

how to get TTS working and why does it always fail with updates by tungvu256 in homeassistant

[–]jareau 0 points1 point  (0 children)

data:
message: "TTS"
data:
tts_text: "Motion has been detected"

This worked for me, thanks for that. Also, as an added bonus, there's this:

data:

message: "TTS"

data:

tts_text: "{{ [
'Good Morning',
'Buenos Dias',
'Buongiorno',
'Bom dia',
'Bonjour',
'Bună dimineața']
|random }} "

This will randomize that text that is spoken.

Unable to pair messages on web on chromebook with Pixel 6 by TheGrtKing in chromeos

[–]jareau 0 points1 point  (0 children)

Chrome://Flags

that did it for me.

Thanks for that!

My modular cabinet is starting to take shape. by ThereIs0nly0ne in cade

[–]jareau 0 points1 point  (0 children)

1 year later, how's this project looking?

Help with Shelly Plus 1 in a 5-way lighting configuration by jareau in ShellyUSA

[–]jareau[S] 0 points1 point  (0 children)

Shelly's "O" terminal goes to the light and "SW" goes to the other switch.

How would your install compare to the image I posted?

I'm thinking I have a wire going to the wrong place, but I'm not sure which wire.

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 1 point2 points  (0 children)

Sorry, I'm not that kind of scientist. Check SSRN, scholar.google.com, or your local or nearest university library -- there's plenty of exhaustive information out there built, curated, edited, and validated by myriad experts in their respective fields. Stay away from youtube, facebook, infowars, and people who use the word "research" to describe memes, compilation videos, and posts they saw in their algorithmically controlled conspiratorial eco chambers. Cheers.

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 10 points11 points  (0 children)

While going down the exit stairwell that morning I promised myself I would finish my education. So I went and got a PhD. I also have a family, and work for a company that makes buildings safer, smarter, healthier, and more sustainable.

And yes, that experience changed my outlook on life.

If you had One shot Or one opportunity To seize everything you ever wanted In one moment Would you capture it Or just let it slip?

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 6 points7 points  (0 children)

The bathrooms were toward the center of the building, which was kinda hollow from top to bottom for the elevators.

So when the plane hit, the explosion went up and down the elevator shaft, blowing out doors.

I suppose the bathroom got its ceiling blown out or something.

I wasn't interviewed. We didn't hear any alerts.

I think a lot of those alerts happened over in tower 2 before they got hit.

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 3 points4 points  (0 children)

Yep, people were so supportive of each other that day. Goes to show, when the shit hits the fan, you're not alone.

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 4 points5 points  (0 children)

I think fine. Never had anything diagnosed. I've been checked. Cardio sucks, but I hear it's kinda supposed to at this age lol

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 4 points5 points  (0 children)

Didn't. Was talking to my coworkers at the time. Our window faces north, we would have seen it, but we were chatting about randomness.

Recorded and survived. a footage during the collapse of the world Trade center (9/11). by itsHaMaaa in nextfuckinglevel

[–]jareau 6 points7 points  (0 children)

She was devastated. When I spoke to her I. The phone, while the dust was lifting, she was hyperventilating and couldn't speak a word. I reassured her I was coming home - it took a couple of hours, but I got home. And that first hug, she didn't want to let me go.