From 20094127c3cbe6e74dc77ed75c81944716a5c761 Mon Sep 17 00:00:00 2001 From: Terts Diepraam Date: Mon, 15 Mar 2021 12:21:08 +0100 Subject: [PATCH] ls: --color back on windows as noop --- src/uu/ls/src/ls.rs | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/uu/ls/src/ls.rs b/src/uu/ls/src/ls.rs index 90e4e2b22..24adaa649 100644 --- a/src/uu/ls/src/ls.rs +++ b/src/uu/ls/src/ls.rs @@ -102,7 +102,6 @@ pub mod options { pub static NUMERIC_UID_GID: &str = "numeric-uid-gid"; pub static REVERSE: &str = "reverse"; pub static RECURSIVE: &str = "recursive"; - #[cfg(unix)] pub static COLOR: &str = "color"; pub static PATHS: &str = "paths"; } @@ -451,13 +450,7 @@ pub fn uumain(args: impl uucore::Args) -> i32 { .long(options::RECURSIVE) .help("List the contents of all directories recursively."), ) - - // Positional arguments - .arg(Arg::with_name(options::PATHS).multiple(true).takes_value(true)); - - #[cfg(unix)] - let app = { - app.arg( + .arg( Arg::with_name(options::COLOR) .long(options::COLOR) .help("Color output based on file type.") @@ -465,7 +458,9 @@ pub fn uumain(args: impl uucore::Args) -> i32 { .require_equals(true) .min_values(0), ) - }; + + // Positional arguments + .arg(Arg::with_name(options::PATHS).multiple(true).takes_value(true)); let matches = app.get_matches_from(args);