Skip to content

nandavereda/under_the_weather

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 

Repository files navigation

under the weather: weather bot for mastodon.

try it out! https://mastodon.social/@UnderTheWeather



Steps to run it:


1) Install dependencies:

pip install Mastodon.py

2) Obtain an api key for openweathermap and save it as openweather_apikey.secret

(Consult openweathermap.org for details)

3) Obtain the mastodon credentials and save them as mastodon_credential.secret

(Consult Mastodon.py documentation for details)



Testing city names directly on API (mastodon credentials not required):


user@host:~/under_the_weather$ python3 openweathermap.py 'Sao Paulo'
Current weather in São Paulo, BR:
clear sky, 32.07 °C

user@host:~/under_the_weather$ python3 openweathermap.py 'São Gonçalo do Amarante'
Current weather in São Gonçalo do Amarante, BR:
few clouds, 27.29 °C

user@host:~/under_the_weather$ python3 openweathermap.py 'københavn'
Current weather in Copenhagen municipality, DK:
light rain, 5.78 °C

About

weather reporter for mastodon

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%