Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 67263 - /etc/profile.d/colorls.sh only applies to the bash shell
/etc/profile.d/colorls.sh only applies to the bash shell
Product: Red Hat Linux
Classification: Retired
Component: fileutils (Show other bugs)
All Linux
medium Severity low
: ---
: ---
Assigned To: wdovlrrw
Aaron Brown
Depends On:
  Show dependency treegraph
Reported: 2002-06-21 13:25 EDT by Nathan G. Grennan
Modified: 2007-04-18 12:43 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-07-01 08:39:41 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Nathan G. Grennan 2002-06-21 13:25:56 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.2.5 (X11; Linux i686; U;) Gecko/0

Description of problem:
/etc/profile.d/colorls.sh only applies to the bash shell because of the line
below. Other shells that use /etc/profile, like zsh, can use the aliases defined
in colorls.sh just fine, but are excluded by the if statement.

if echo $SHELL |grep bash 2>&1 >/dev/null; then # aliases are bash only

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Install fileutils and zsh
2. chsh -s zsh user
3. login as user
4. ls

Actual Results:  No color on directories and files.

Expected Results:  Color on directories and files.

Additional info:
Comment 1 Bernhard Rosenkraenzer 2002-07-01 08:39:37 EDT
Agreed, fixed in 4.1.9-1. 
I'm now simply using 
alias foo=bar 2>/dev/null 
So it gets executed on any shell, but the ones not supporting it don't spew 
error messages. (Much better than hardcoding shell names)

Note You need to log in before you can comment on or make changes to this bug.