diff --git a/Cargo.toml b/Cargo.toml index 909fd86af..4300f56e6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,6 +20,7 @@ exclude = [ appveyor = { repository = "phsym/prettytable-rs", branch = "master", service = "github" } travis-ci = { repository = "phsym/prettytable-rs", branch = "master" } codecov = { repository = "phsym/prettytable-rs", branch = "master", service = "github" } +maintenance = { status = "passively-maintained" } [features] default = ["win_crlf", "csv"] @@ -38,6 +39,6 @@ name = "prettytable" unicode-width = "0.1" term = "0.7" lazy_static = "1" -atty = "0.2" +is-terminal = "0.4" encode_unicode = "1" csv = { version = "1", optional = true } diff --git a/README.md b/README.md index 714b7dc14..548202f2a 100644 --- a/README.md +++ b/README.md @@ -6,11 +6,6 @@ [![Doc.rs](https://docs.rs/prettytable-rs/badge.svg)](https://docs.rs/crate/prettytable-rs/) [![Doc.rs](https://img.shields.io/badge/docs-master-blue.svg)](http://phsym.github.io/prettytable-rs/master) -> This crate has been abandonned without notice for quite a while due to some personnal reasons. My apologies for that. -I'll try to do my best to continue to maintain it, at least for security updates. If I can't the find time to do it, I'll have no other option than -deprecating it, or find new contributors to handover the maintenance to. Feel free to raise your hand if you're interrested. -In the meantime, please expect a low update rate, and again please accept my apologies. - # prettytable-rs A formatted and aligned table printer library for [Rust](https://www.rust-lang.org). @@ -45,7 +40,7 @@ Include the library as a dependency to your project by adding the following line prettytable-rs = "^0.9" ``` -The library requires at least `rust v1.32.0`. +The library requires at least `rust v1.41`. ## Basic usage diff --git a/src/lib.rs b/src/lib.rs index 8d6ae3912..5b5d8e4cd 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -193,7 +193,8 @@ impl<'a> TableSlice<'a> { /// # Returns /// A `Result` holding the number of lines printed, or an `io::Error` if any failure happens pub fn print_tty(&self, force_colorize: bool) -> Result { - match (stdout(), atty::is(atty::Stream::Stdout) || force_colorize) { + use is_terminal::IsTerminal; + match (stdout(), io::stdout().is_terminal() || force_colorize) { (Some(mut o), true) => self.print_term(&mut *o), _ => self.print(&mut io::stdout()), }