dejankos / istramet-cli

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Istramet CLI

Build Status

Cli tool for fetching weather forecast from the local web I usually follow.
Main motivation for this project was one afternoon of boredom.

Usage

istramet-cli 0.1.0

USAGE:
    imet [OPTIONS] [city]

FLAGS:
    -h, --help       Prints help information
    -V, --version    Prints version information

OPTIONS:
    -d, --days <days>    Number of days to display name. Default is all available

ARGS:
    <city>    City name [default: porec]

Example

Fetch all weather for some city

imet porec

Fetch weather for next 3 days

imet porec -d 3

Example output

+------------------+---------+------+---------+----------+----------+---------+----------+
| Sat              | Vrijeme | Temp | Oborine | VlaΕΎnost | Tlak     | Vjetar  | Naoblaka |
+------------------+---------+------+---------+----------+----------+---------+----------+
|                  |         |      |         |          |          |         |          |
+------------------+---------+------+---------+----------+----------+---------+----------+
| Danas            |         |      |         |          |          |         |          |
+------------------+---------+------+---------+----------+----------+---------+----------+
|                  |         |      |         |          |          |         |          |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 20h              | 🌞      | 17Β°  |         | 78 %     | 1016 hPa | β†– 1 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 21h              | πŸŒ™      | 17Β°  |         | 76 %     | 1016 hPa | ↑ 1 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 22h              | πŸŒ™      | 16Β°  |         | 84 %     | 1016 hPa | β†— 2 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 23h              | πŸŒ™      | 16Β°  |         | 84 %     | 1016 hPa | β†’ 2 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| Sutra            |         |      |         |          |          |         |          |
+------------------+---------+------+---------+----------+----------+---------+----------+
|                  |         |      |         |          |          |         |          |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 00h              | πŸŒ™      | 15Β°  |         | 89 %     | 1016 hPa | β†’ 1 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 01h              | πŸŒ™      | 15Β°  |         | 84 %     | 1016 hPa | β†’ 2 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 02h              | ☁       | 16Β°  |         | 82 %     | 1016 hPa | β†’ 1 m/s | 2/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 03h              | ☁       | 16Β°  |         | 81 %     | 1015 hPa | β†’ 1 m/s | 2/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 04h              | ☁       | 16Β°  |         | 75 %     | 1015 hPa | β†’ 2 m/s | 6/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 05h              | ☁       | 15Β°  |         | 79 %     | 1015 hPa | β†’ 2 m/s | 9/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 06h              | β›…      | 15Β°  |         | 74 %     | 1015 hPa | β†’ 2 m/s | 8/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 07h              | ☁       | 16Β°  |         | 68 %     | 1015 hPa | β†’ 3 m/s | 3/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 08h              | 🌞      | 18Β°  |         | 71 %     | 1015 hPa | β†’ 2 m/s | 1/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 09h              | 🌞      | 19Β°  |         | 55 %     | 1015 hPa | β†’ 1 m/s | 1/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 10h              | β›…      | 19Β°  |         | 67 %     | 1015 hPa | ← 1 m/s | 4/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 11h              | ☁       | 19Β°  |         | 71 %     | 1016 hPa | ← 3 m/s | 2/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 12h              | ☁       | 19Β°  |         | 75 %     | 1016 hPa | ← 3 m/s | 2/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 13h              | 🌞      | 19Β°  |         | 73 %     | 1016 hPa | ← 3 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 14h              | 🌞      | 19Β°  |         | 70 %     | 1015 hPa | ← 2 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 15h              | 🌞      | 19Β°  |         | 69 %     | 1015 hPa | β†– 2 m/s | 0/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 16h              | ☁       | 19Β°  |         | 68 %     | 1014 hPa | β†– 2 m/s | 2/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 17h              | ☁       | 19Β°  |         | 68 %     | 1014 hPa | β†– 3 m/s | 4/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 18h              | β›…      | 19Β°  |         | 68 %     | 1014 hPa | β†– 3 m/s | 4/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 19h              | β›…      | 19Β°  |         | 69 %     | 1014 hPa | ↑ 3 m/s | 5/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 20h              | β›…      | 18Β°  |         | 75 %     | 1014 hPa | ↑ 3 m/s | 5/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 21h              | ☁       | 18Β°  |         | 76 %     | 1015 hPa | ↑ 4 m/s | 4/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 22h              | ☁       | 17Β°  |         | 76 %     | 1016 hPa | β†— 5 m/s | 5/10     |
+------------------+---------+------+---------+----------+----------+---------+----------+
| 23h              | ☁       | 17Β°  |         | 78 %     | 1016 hPa | β†— 4 m/s | 2/10     |

Installation

Download latest precompiled executable (Linux|WSL2/OSX) from release page and add to system path. Add executable to PATH in ~/.bashrc or to /usr/local/bin.

License

Istramet-cli is licensed under the Apache License, Version 2.0

About

License:Apache License 2.0


Languages

Language:Rust 77.4%Language:Shell 22.6%