/node-weather-cli

Primary LanguageJavaScriptMIT LicenseMIT


Node Weather CLI


Simple Weather CLI build with Node

About The Project

A simple weather CLI using OpenWeather and mapbox APIs using ECMAScript modules (ESM) in Node

(back to top)

Getting Started

Prerequisites

  1. Node.js and npm installed

Installation

  1. Get free API keys for Mapbox and OpenWeather

  2. Clone the repo

    git clone git@github.com:kolberg-dev/node-weather-cli.git
    cd node-weather-cli
  3. Install NPM packages

    npm install
  4. Make an dotenv file .env with the following content

    MAPBOX_API_KEY = yourMapboxApiKey
    OPENWEATHERMAP_API_KEY = yourOpenWeatherApiKey

(back to top)

Usage

Screenshot of the help dialog

Run the program with:
node weather.js <location>

Screenshot of the location menu

Choose the most accurat location in the menu

Screenshot of result

(back to top)