
Vari

Vari (Väri) is a Rust library for formatting strings with colors and cosmetic stuff to the terminal. Like Rich library for Python.
Installing
[dependencies]
vari = "0.1.5"
Features
Color Anchor
fn main() {
let message = vari::format("[$blue]Hello, [$green]World![$/]");
println!("{}", message);
println!("{}", vari::format("[$[114, 119, 39]]#727727![$[66, 4, 32]] Do you see it?[$/]"));
vprintln!("{}Bold and Italic :O{}", "[$bold][$italic]", "[$/]");
vprintln!("{}Backgroundssss{}[$/]", "[bg$magenta]", "[bg$[188, 188, 188]]World![$/]")
}
Macros
fn main() {
let f = vformat!("{}Hello!{}", "[$bright_magenta]", "[$/]");
println!("{}", f);
vprintln!("{}I'm feeling {}{}", "[$italic][$yellow]", "lazy" "$[/]");
}
Fun
fn main() {
println!("{}", vari::fun::rainbow("Rainbow!!!"));
}
License
This crate is under AGPL-3.0 license.