[package] name = "should-color" version = "0.5.2" authors = ["Federico Stra "] description = "Determine whether output should use colors or not." license = "MIT" repository = "https://github.com/FedericoStra/should-color" categories = ["command-line-interface"] keywords = ["cli", "color", "clicolor", "no_color", "terminal"] edition = "2021" exclude = ["/Makefile"] # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [features] default = ["clicolor", "clicolor_force", "no_color", "stream"] ## Enables the detection of [`CLICOLOR`](#clicolor) via [`clicolor`]. clicolor = [] ## Enables the detection of [`CLICOLOR_FORCE`](#clicolor_force) via [`clicolor_force`]. clicolor_force = [] ## Enables the detection of [`NO_COLOR`](#no_color) via [`no_color`]. no_color = [] ## Adds [`ColorChoice::for_stream`]. stream = ["dep:atty"] ## Adds [`clap_color`] and conversion of [`ColorChoice`] to and from ## [`clap::ColorChoice`](https://docs.rs/clap/latest/clap/enum.ColorChoice.html). clap = ["dep:clap"] [dependencies] atty = { version = "0.2.14", optional = true } clap = { version = "3.2.20", features = ["color", "derive", "std"], default-features = false, optional = true } document-features = { version = "0.2.5", git = "https://github.com/slint-ui/document-features", rev = "edcf2a9f74cf28f461b506be9dafe28359967cdc" } [dev-dependencies] clap = { version = "3.2.20", features = ["cargo", "derive"] } colored = "2.0.0" itertools = "0.10.3" termcolor = "1.1.3" [package.metadata.docs.rs] rustdoc-args = ["--cfg", "docsrs", "--html-in-header", "header.html"] targets = ["x86_64-unknown-linux-gnu"] all-features = true [[example]] name = "colored" required-features = ["clap", "stream"] [[example]] name = "termcolor" required-features = ["clap", "stream"]