Giter Site home page Giter Site logo

weather-rs's Introduction

weather-rs

GitHub code size in bytes GitHub Downloads (all assets, all releases) rust workflow License: MIT

About ๐Ÿ’ญ

Simple weather cli to check for weather based on current IP geolocation or an explicitly stated city. Written in Rust.

Features โœจ

  • Shows the following information
    • Location
      • Country
      • City
      • Latitude
      • Longtitude
    • Weather
      • Forecast (Clear, Partly Cloudy, etc.)
      • Temperature
      • Apparent Temperature
      • Humidity
      • Precipitation
      • Wind Speed
    • Time of last update
  • Gets weather by your IP's location
  • Gets weather for a specific city

Building ๐Ÿ”จ

For the following distributions, it's available for install here:

  • ArchLinux, you can use aur.

For other distributions, or people that want to do a manual install:

Dependencies

In order to build from source, you must have the following installed:

Build commands

# Clone the source code
git clone [email protected]:einstein8612/weather-rs.git
cd weather-rs

# Build the binary
cargo build --release
# Optional: Move to bin, if you want to use it everywhere
sudo mv target/release/weather-rs /usr/bin/weather

Usage ๐Ÿ•น๏ธ

Example #1:

Showcases IP geolocation guessing current location.

$ weather
โ•ญโ”€Locationโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ Country: The Netherlands      โ”‚
โ”‚ City: North Holland/Amsterdam โ”‚
โ”‚ Latitude: 52.3667             โ”‚
โ”‚ Longtitude: 4.9               โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
โ•ญโ”€Weatherโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ Forecast: Overcast           โ”‚
โ”‚ Temperature: 9.2ยฐC           โ”‚
โ”‚ Apparent Temperature: 3.2ยฐC  โ”‚
โ”‚ Humidity: 81%                โ”‚
โ”‚ Precipitation: 0mm           โ”‚
โ”‚ Wind Speed: 35km/h           โ”‚
โ”‚ Last updated: 4  minutes ago โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

Example #2:

Showcases overwriting the city

$ weather -c NYC
โ•ญโ”€Locationโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ Country: United States        โ”‚
โ”‚ City: New York                โ”‚
โ”‚ Latitude: 40.71427            โ”‚
โ”‚ Longtitude: -74.00597         โ”‚
โ”‚ Population: 8175133           โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
โ•ญโ”€Weatherโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ Forecast: Clear               โ”‚
โ”‚ Temperature: 1.2ยฐC            โ”‚
โ”‚ Apparent Temperature: -4.1ยฐC  โ”‚
โ”‚ Humidity: 41%                 โ”‚
โ”‚ Precipitation: 0mm            โ”‚
โ”‚ Wind Speed: 13.3km/h          โ”‚
โ”‚ Last updated: 6 minutes ago   โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

APIs used

weather-rs's People

Contributors

einstein8612 avatar

Stargazers

 avatar Pavel Savchenko avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.