From owner-svn-src-head@freebsd.org Fri Aug 17 15:48:08 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D48CA10730BF; Fri, 17 Aug 2018 15:48:08 +0000 (UTC) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: from pdx.rh.CN85.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 45D99845AD; Fri, 17 Aug 2018 15:48:08 +0000 (UTC) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: from pdx.rh.CN85.dnsmgr.net (localhost [127.0.0.1]) by pdx.rh.CN85.dnsmgr.net (8.13.3/8.13.3) with ESMTP id w7HFm52L059917; Fri, 17 Aug 2018 08:48:05 -0700 (PDT) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: (from freebsd@localhost) by pdx.rh.CN85.dnsmgr.net (8.13.3/8.13.3/Submit) id w7HFm5xA059916; Fri, 17 Aug 2018 08:48:05 -0700 (PDT) (envelope-from freebsd) From: "Rodney W. Grimes" Message-Id: <201808171548.w7HFm5xA059916@pdx.rh.CN85.dnsmgr.net> Subject: Re: svn commit: r337956 - in head: . bin/ls In-Reply-To: To: Kyle Evans Date: Fri, 17 Aug 2018 08:48:05 -0700 (PDT) CC: "Rodney W. Grimes" , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Reply-To: rgrimes@freebsd.org X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Aug 2018 15:48:09 -0000 > On Fri, Aug 17, 2018 at 10:24 AM, Rodney W. Grimes > wrote: > > [ Charset UTF-8 unsupported, converting... ] > >> Author: kevans > >> Date: Fri Aug 17 04:15:51 2018 > >> New Revision: 337956 > >> URL: https://svnweb.freebsd.org/changeset/base/337956 > >> > >> Log: > >> ls(1): Add --color=when > >> > >> --color may be set to one of: 'auto', 'always', and 'never'. > >> > >> 'auto' is the default behavior- output colors only if -G or COLORTERM are > > > > Why different than coreutils ls? Default for coreutils is none. > > I guess this was worded poorly and you skipped both the review and > reading the diff... this is still contingent on environment variables > or -G being specified. The review lasted for less time than I had to respond, it was also evolving with changes from 0mp and cem. I can not typically respond to any review in less than 24 hours, and usually need more like 48. > > >> set, and only if stdout is a tty. > >> > >> 'always' is a new behavior- output colors always. termcap(5) will be > >> consulted unless TERM is unset or not a recognized terminal, in which case > >> ls(1) will fall back to explicitly outputting ANSI escape sequences. > >> > >> 'never' to turn off any environment variable and -G usage. > > Why different than core utils? Coreutils uses none. > > I guess this was worded poorly and you skipped both the review and > reading the diff... this is still contingent on environment variables > or -G being specified. Is the word never or none? It looks prettyh clear to me in the diff: else if (strcmp(optarg, "never") == 0) 414 colorflag = COLORFLAG_NEVER; 415 else Let me repeat, coreutils ls uses color==none not color==never, the default in coreutils ls is color==none this is NOT depedent on any environment variables. Can we please bring our ls into conformance with: https://www.gnu.org/software/coreutils/manual/html_node/General-output-formatting.html in respect to how --color works? IMHO, doing anything different is a huge POLA issue. > Thanks, > Kyle Evans Thanks, -- Rod Grimes rgrimes@freebsd.org