mirror of
https://github.com/eliasrenman/dotfiles.git
synced 2026-03-16 20:46:08 +01:00
chore: moved to support stow
This commit is contained in:
9
.config/waybar/scripts/weather.sh
Executable file
9
.config/waybar/scripts/weather.sh
Executable file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
LOC="$1"
|
||||
# HTML encode string as %20
|
||||
TEMP=$(curl -s 'https://wttr.in/'${LOC}'?format=%t\n&m')
|
||||
ICON=$(curl -s 'https://wttr.in/'${LOC}'?format=1' | grep -o '^\S*' )
|
||||
# echo $ICON
|
||||
echo '{"text": "'$TEMP'", "tooltip": "'$ICON' '$LOC'", "class": "weather" }'
|
||||
|
||||
Reference in New Issue
Block a user