buche

Crates.iobuche
lib.rsbuche
version0.7.0
sourcesrc
created_at2023-01-10 18:07:32.408965
updated_at2023-01-10 18:13:53.242688
descriptionLogger that logs to stderr based on verbosity specified
homepagehttps://github.com/delehef/buche
repositoryhttps://github.com/delehef/buche
max_upload_size
id755734
size102,073
(delehef)

documentation

https://docs.rs/buche/

README

A fork of stderrlog, a logger that aims to provide a simple case of env_logger that just logs to stderr based on verbosity.

Documentation

For a working example for StructOpt, clap, and docopt please see the crate level documentation.

For example binaries showing how module level logging works, please see the large-example crate in examples/.

Usage

Add this to your Cargo.toml:

[dependencies]
buche = "0.6"

and this to your main():

buche::new().verbosity(args.flag_v).quiet(args.flag_q).init().unwrap();

where your args struct is defined as:

struct Args {
    flag_v: usize,
    flag_q: bool,
    ...
}
Commit count: 190

cargo fmt