How to Install Wego tool - A weather App in Linux

To Install Wego tool - A weather App in Linux

Wego tool is a weather application software to view weather in ASCII. It displays the wind speed and direction, temperature, viewing distance, and the precipitation amount. It has the ability to display the weather forecast information for 8 days. Installation of Wego is explained in this manual.


To Install Wego

Install the dependency packages by entering the following command.

root@linuxhelp:/home/user1/Desktop# apt-get install golang-go git
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  git-man golang-1.6-go golang-1.6-race-detector-runtime golang-1.6-src golang-race-detector-runtime golang-src liberror-perl
...
....
...
Setting up golang-1.6-go (1.6.2-0ubuntu5~16.04) ...
Setting up golang-src (2:1.6-1ubuntu4) ...
Setting up golang-go (2:1.6-1ubuntu4) ...
Setting up golang-1.6-race-detector-runtime (0.0+svn252922-0ubuntu1) ...
Setting up golang-race-detector-runtime (2:1.6-1ubuntu4) ...

Install the wego tool using the following commands

root@linuxhelp:/home/user1/Desktop# export GOPATH=/home/user1/gocode
root@linuxhelp:/home/user1/Desktop# go get github.com/schachmat/wego
root@linuxhelp:/home/user1/Desktop# cd /home/user1/gocode/
root@linuxhelp:/home/user1/gocode# ll
total 20
drwxr-xr-x  5 root  root  4096 Jul 18 13:16 ./
drwxr-xr-x 17 user1 user1 4096 Jul 18 13:16 ../
drwxr-xr-x  2 root  root  4096 Jul 18 13:16 bin/
drwxr-xr-x  3 root  root  4096 Jul 18 13:16 pkg/
drwxr-xr-x  3 root  root  4096 Jul 18 13:16 src/
root@linuxhelp:/home/user1/gocode# cd bin/
root@linuxhelp:/home/user1/gocode/bin# ll
total 8700
drwxr-xr-x 2 root root    4096 Jul 18 13:16 ./
drwxr-xr-x 5 root root    4096 Jul 18 13:16 ../
-rwxr-xr-x 1 root root 8899808 Jul 18 13:16 wego*
root@linuxhelp:/home/user1/gocode/bin# ./wego
2016/07/18 13:17:22 No forecast.io API key specified.
You have to register for one at https://developer.forecast.io/register

Registration

API Key

root@linuxhelp:/home/user1/gocode/bin# nano ~/.wegorc

Add the API key to the file, then save the file and exit.


To Launch Wego

Run the following command to launch Wego.

root@linuxhelp:/home/user1/gocode/bin# ./wego

Weather for 40.748001-73.985001

Use the latitude and longitude of the city to view the weather forecast of a city.

Change the number of days to the max of 8 in the wegorc configuration file to view weather forecast of 8 days.

Enjoy forecasting!!!

FAQ
Q
What is the command to see weather report of particular city in wego?
A
following command is used to see weather report of particular city

# wego "cityname"
Q
How to view 5 days or more weather report in wego?
A
You can use the wego command with number days you want to get the weather report.
EXAMPLE
# wego 5 //To get the weather report for 5 days
Q
Where to find the binary file of wego in Linux?
A
The binary file is located inside the bin directory of installed location.
Q
How to view news from my terminal ?
A
There is a tool called "instantnews" which can suit your need. To install follow the following commands
#yum install python-pip
#pip install instantnews
#vim ~/.bashrc
export IN_API_KEY="Paste-API-key-here"
Q
How to see the weather report in command line?
A
Simply, type the command "wego", To see weather report in the command line