weather widget for 9front that uses the OpenWeatherMap API.
q / Del to quit
9weather [ -d seconds ] [ -i ] [ -z zip,country ] [ -k apikey ]
9weather retrieves weather data from OpenWeatherMap and requires an API key for access. You can easily obtain a free API key by registering at http://openweathermap.org/
By default, 9weather fetches weather data every 5 minutes. This interval can be changed by setting the -d flag, followed by the desired delay in seconds.
9weather normally displays the temperature in metric units, to display in imperial units add the -i flag.
9weather obtains the API key by default from factotum(4). You can add an entry like:
key proto=pass service=9weather user=openweathermap !password=my_api_key
If factotum does not contain the key, 9weather will try to read it from the environment variable openweathermap. You can also manually specify the API key using the -k flag.
The geolocation ZIP code is obtained from the environment variable ZIP by default. You can manually specify a ZIP code using the -z flag.
9weather -z Shanghai -k my_api_key
MIT
