Bug 86298
Summary: | automatically do color ls if CLICOLOR (or LS_COLORS) are set | ||||||
---|---|---|---|---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | Michael Wardle <michael.wardle> | ||||
Component: | coreutils | Assignee: | Tim Waugh <twaugh> | ||||
Status: | CLOSED CANTFIX | QA Contact: | |||||
Severity: | medium | Docs Contact: | |||||
Priority: | low | ||||||
Version: | 9 | CC: | mattdm, mitr | ||||
Target Milestone: | --- | Keywords: | FutureFeature | ||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Enhancement | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2007-01-02 18:23:28 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Michael Wardle
2003-03-19 05:49:02 UTC
I prefer the method employed by FreeBSD, which is to automatically color the output if the environment variable CLICOLOR is set and the output is a TTY, negating the need for any shell aliases, which can cause some problems (one of which I mentioned above). I have just sent a patch to bug-coreutils to add this functionality to GNU ls. I will also attach it here in case you would like to adopt it for your package. Created attachment 90657 [details]
automatically produce color output if $CLICOLOR is set
After reflecting on this, I realize that "which ls" can validly return an alias rather than a path to an executable file, so this is not strictly a bug. Still, I like the FreeBSD method, and I'd be happy if you could consider the attached patch, which should save some amount of mess in login scripts (/etc/profile.d/ and the like). You might also note that the provided patch can very easily be modified to default to color ls if LS_COLORS is set rather than CLICOLOR. I'll wait and see if it's adopted upstream I think. Red Hat apologizes that these issues have not been resolved yet. We do want to make sure that no important bugs slip through the cracks. Red Hat Linux 7.3 and Red Hat Linux 9 are no longer supported by Red Hat, Inc. They are maintained by the Fedora Legacy project (http://www.fedoralegacy.org/) for security updates only. If this is a security issue, please reassign to the 'Fedora Legacy' product in bugzilla. Please note that Legacy security update support for these products will stop on December 31st, 2006. If this is not a security issue, please check if this issue is still present in a current Fedora Core release. If so, please change the product and version to match, and check the box indicating that the requested information has been provided. If you are currently still running Red Hat Linux 7.3 or 9, please note that Fedora Legacy security update support for these products will stop on December 31st, 2006. You are strongly advised to upgrade to a current Fedora Core release or Red Hat Enterprise Linux or comparable. Some information on which option may be right for you is available at http://www.redhat.com/rhel/migrate/redhatlinux/. Any bug still open against Red Hat Linux 7.3 or 9 at the end of 2006 will be closed 'CANTFIX'. Again, if this bug still exists in a current release, or is a security issue, please change the product as necessary. We thank you for your help, and apologize again that we haven't handled these issues to this point. Red Hat Linux 7.3 and Red Hat Linux 9 are no longer supported by Red Hat, Inc. f you are currently still running Red Hat Linux 7.3 or 9, you are strongly advised to upgrade to a current Fedora Core release or Red Hat Enterprise Linux or comparable. Some information on which option may be right for you is available at http://www.redhat.com/rhel/migrate/redhatlinux/. Closing as CANTFIX. |