Simple script which uses the Wttr.in Api to display location based weather information in i3blocks.
If a location is not provided via the command line, the script will automatically locate you using your IP address. This obviously doesn't work if you use a VPN. In that case, you must specify your location on the command line.
Location data is provided by IP-API.com (it works better than Wttr default). They automatically ban any IP address that exceeds 150 requests per minute.
python3.7
requests
Weather Icons
# Current weather
#
# The script may be called with -s (for short input), -f (for input in farenheit) and -c (to specify city) switches,
# see the script for details.
[weather]
command=$SCRIPT_DIR/weather.py
interval=3600
markup=pango