Short Bytes: If you are a coder who is in love with his/her work, then outside weather doesn’t matter much to you. However, if you’re heading for a walk to refresh your mind, just type this command in Terminal and get the weather report instantly 😉
Today, I discovered this cool way to read the weather forecast with a single command and I’m going to share it with you. All you need to do is open the terminal and paste the following command with the name of the desired city:
curl -4 http://wttr.in/CityName
As soon as you enter the command, a beautiful forecast of the whole week’s weather is presented inside your Terminal window. It’s actually an ASCII-rendering of the online frontend of the a console weather application Wego. You can access it directly at http://wttr.in
Apart from the weather of cities, you can use 3-letter airport codes and IP-addresses or domain names prefixed with @ for specifying location:
curl -4 http:[email protected]
To see this extra information online, you can run this command to access help:
curl -4 http://wttr.in/:help
Did you like this command for getting the weather updates inside the terminal? Do you know some more geeky Terminal commands? Share your views in the comments below.
Choose your own Learn To Code Bundle at fossBytes Store.