New backup 2024-04-24 13:45:02
This commit is contained in:
parent
b97eff00bb
commit
31b04e3b3c
2 changed files with 9 additions and 6 deletions
|
@ -10,4 +10,4 @@ options=$( ls "$HOME/.config/sway/scripts/global_shortcuts/" )
|
||||||
|
|
||||||
op=$( echo -e "${options}" | wofi -i --dmenu | awk '{print}' )
|
op=$( echo -e "${options}" | wofi -i --dmenu | awk '{print}' )
|
||||||
|
|
||||||
"$HOME/.config/sway/scripts/shortcuts/${current_ws}"/"${op}"
|
"$HOME/.config/sway/scripts/global_shortcuts/${op}"
|
||||||
|
|
|
@ -1,13 +1,16 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
jweather=$( curl --silent wttr.in/?format=j1 )
|
#jweather=$( curl --silent wttr.in/?format=j1 )
|
||||||
|
jweather=$( cat ~/weather.json )
|
||||||
|
|
||||||
current_f=$( jq -r '.current_condition.[].FeelsLikeF' <<< ${jweather} )
|
current_f=$( jq -r '.current_condition.[].FeelsLikeF' <<< ${jweather} )
|
||||||
high_f=$( jq -r '.weather.[0].maxtempF' <<< ${jweather} )
|
high_f=$( jq -r '.weather.[0].maxtempF' <<< ${jweather} )
|
||||||
low_f=$( jq -r '.weather.[0].mintempF' <<< ${jweather} )
|
low_f=$( jq -r '.weather.[0].mintempF' <<< ${jweather} )
|
||||||
weather_desc=$( jq -r '.current_condition.[].weatherDesc.[].value' <<< ${jweather} )
|
weather_desc=$( jq -r '.current_condition.[].weatherDesc.[].value' <<< ${jweather} )
|
||||||
|
for d in 1..5;do
|
||||||
|
date -d $( jq -r ".weather.[$d].date" <<< ${jweather} ) +'%A'
|
||||||
|
done
|
||||||
|
|
||||||
notify-send "${current_f}°F ${weather_desc}
|
notify-send "Current: ${current_f}°F ${weather_desc}
|
||||||
High: ${high_f}
|
High: ${high_f}°F | Low: ${low_f}°F
|
||||||
Low: ${low_f}
|
${Forecast}"
|
||||||
"
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue