New backup 2025-05-06 14:08:20

This commit is contained in:
Penelope Gwen 2025-05-06 14:08:20 -07:00
parent daa2b45e07
commit 9175b16f05

View file

@ -4,13 +4,13 @@ hass_weather_cache="${HOME}/.cache/hass_weather.json"
update_cache_json(){
weather_summary="$( hass-cli -a states -i sensor.weather_summary | jq -r '.attributes' )"
condition="$( jq '.condition' <<< ""${weather_summary}"" )"
condition_code="$( jq '.condition_code' <<< ""${weather_summary}"" )"
current_temp="$( jq '.current_temp' <<< ""${weather_summary}"" )"
feels_temp="$( jq '.feels_temp' <<< ""${weather_summary}"" )"
min_temp="$( jq '.min_temp' <<< ""${weather_summary}"" )"
max_temp="$( jq '.max_temp' <<< ""${weather_summary}"" )"
humidity="$( jq '.humidity' <<< ""${weather_summary}"" )"
condition="$( jq -r '.condition' <<< ""${weather_summary}"" )"
condition_code="$( jq -r '.condition_code' <<< ""${weather_summary}"" )"
current_temp="$( jq -r '.current_temp' <<< ""${weather_summary}"" )"
feels_temp="$( jq -r '.feels_temp' <<< ""${weather_summary}"" )"
min_temp="$( jq -r '.min_temp' <<< ""${weather_summary}"" )"
max_temp="$( jq -r '.max_temp' <<< ""${weather_summary}"" )"
humidity="$( jq -r '.humidity' <<< ""${weather_summary}"" )"
updated="$(date '+%Y-%m-%d, %H:%M')"
case "${condition_code}" in