mirror of
https://github.com/nushell/nushell.git
synced 2025-01-03 04:50:28 +01:00
remove is terminal check for table colors
This commit is contained in:
parent
556585fba7
commit
39efa034b9
@ -15,13 +15,7 @@ use nu_table::{
|
||||
StringResult, TableOpts, TableOutput,
|
||||
};
|
||||
use nu_utils::{get_ls_colors, terminal_size};
|
||||
use std::{
|
||||
collections::VecDeque,
|
||||
io::{IsTerminal, Read},
|
||||
path::PathBuf,
|
||||
str::FromStr,
|
||||
time::Instant,
|
||||
};
|
||||
use std::{collections::VecDeque, io::Read, path::PathBuf, str::FromStr, time::Instant};
|
||||
use url::Url;
|
||||
|
||||
const STREAM_PAGE_SIZE: usize = 1000;
|
||||
@ -1117,8 +1111,7 @@ enum TableView {
|
||||
}
|
||||
|
||||
fn maybe_strip_color(output: String, config: &Config) -> String {
|
||||
// the terminal is for when people do ls from vim, there should be no coloring there
|
||||
if !config.use_ansi_coloring.get() || !std::io::stdout().is_terminal() {
|
||||
if !config.use_ansi_coloring.get() {
|
||||
// Draw the table without ansi colors
|
||||
nu_utils::strip_ansi_string_likely(output)
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user