SkillAgentSearch skills...

WeatherFetcher

Small program that uses online APIs to fetch current information about the weather (could be added to bashrc file).

Install / Use

/learn @alavifazel/WeatherFetcher
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

WeatherFetcher

WeatherFetcher is a boost-powered small program that determines your location based on your IP address and fetches your current weather information using online APIs. This program was written to be added to my .bashrc file which makes it run on terminal startup. dependencies:

  • RapidJSON
  • Boost.beast

Building

In order to build this project, follow these steps:

  1. Sign up on free on OpenWeatherMap and get a token.
  2. Replace the token you received by <Token> in main function.
  3. Download RapidJSON and put its include directory in the root of the project.
  4. Install the latest version of Boost library.
  5. Create a directory called build in the project's root and cd into it and run (without $):
$ cmake ...
$ make
  1. Now you have weatherFetcher compiled and ready to be added to your .bashrc file.

example output:

Temperature: 33.15°
Humidity: 21%
Condition:

\ / 
(O)-   (CLEAR)
/ \
--------------------

Current ascii arts:

  • Atomosphere
______
~~~~~~  (ATMOSPHERIC)
------   
  • Clear
\ / 
(O)-   (CLEAR)
/ \
--------------------
  • Clouds
      .-~~~-.
  .--(       )_____
 /                 `-~ -
|                       \       (CLOUDS)
 \                     .'
   ~- . ___________ -~
  • Drizzle
      .-~~~-.
  .--(       )_____
 /                 `-~ -        (DRIZZLE)
|                       \
 \  `   `  `  `  ` `   .'
   \`_`__`_` -`~--- `-- 
  ` ` ``  ` ` ` `  `  `
  • Rain
      .-~~~-.
  .--(       )_____
 /                 `-~ -        (RAIN)
|                       \
 \                     .'
 / /-/ /_/_/_/_____ -~
/ / / / / / /
 / / / / / /
  • Snow
         ,\/,
       _\_\/_/_   (SNOW)
        / /\ \
         '/\'
  • Thunderstorm

\   \
 \   \_
  \_   \
     \  \_     (THUNDER)
      \__ \
          \\
           \\
            \\

Related Skills

View on GitHub
GitHub Stars5
CategoryDevelopment
Updated1y ago
Forks0

Languages

C++

Security Score

70/100

Audited on Nov 20, 2024

No findings