Vendor the command set the menu and shell depend on

This commit is contained in:
2026-09-19 23:57:12 -04:00
parent 9501f2bb4d
commit c5434026a8
179 changed files with 12414 additions and 54 deletions
+24
View File
@@ -0,0 +1,24 @@
#!/bin/bash
# blob:summary=Returns a formatted weather status string with temperature and wind speed.
place=$(blob-weather-location 2>/dev/null)
if [[ -z $place ]]; then
echo "Weather unavailable"
exit 1
fi
query=$(jq -rn --arg place "$place" '$place | @uri')
weather=$(curl -fsS --max-time 4 "https://wttr.in/${query}?format=%t|%w" 2>/dev/null | tr -d '\n')
if [[ -z $weather ]]; then
echo "Weather unavailable"
exit 1
fi
IFS='|' read -r temperature wind <<< "$weather"
place=${place^}
temperature=${temperature#+}
echo "$place · Temp $temperature · Wind $wind"