A lightweight command-line tool written in Rust to fetch weather information using wttr.in. This tool allows you to quickly retrieve weather data for specified locations in your preferred language, with simple CLI options.
- Fetch weather for multiple locations.
- Option to specify the language of weather details.
- Clean and fast asynchronous HTTP requests with
reqwest. - Implements the
wttr.inAPI for weather reports.
-
Clone the repository:
git clone https://github.com/R-udren/wttr-cli-rs.git cd wttr-cli-rs -
Build the project using Cargo:
cargo build --release
-
Run the compiled binary:
./target/release/wttr-cli
Fetch weather information from wttr.in
Usage: wttr-cli.exe [OPTIONS] [LOCATIONS]...
Arguments:
[LOCATIONS]... City/location names to get the weather for. [default: ]
Options:
-l, --lang <LANG> Specify the language (e.g., ru, fr, de). [default: en]
-h, --help Print help
-V, --version Print version-
Fetch the weather for New York (English):
wttr-cli "New York" -
Fetch the weather for Paris in French:
wttr-cli "Paris" -l fr -
Fetch the weather for multiple locations:
wttr-cli "Berlin" "Tokyo" "Delhi"
This project uses the following Rust dependencies:
reqwest: Asynchronous HTTP client for making API requests.clap: Command-line argument parsing.tokio: Asynchronous runtime for running async tasks.
Contributions are welcome! Feel free to open an issue or submit a pull request if you'd like to contribute improvements or fixes to the project.
This project is licensed under the MIT License. See the LICENSE file for details.


