Bug 126994 - OPTIONS not used from /etc/DIR_COLORS file
OPTIONS not used from /etc/DIR_COLORS file
Product: Fedora
Classification: Fedora
Component: coreutils (Show other bugs)
i386 Linux
medium Severity low
: ---
: ---
Assigned To: Tim Waugh
Depends On:
Blocks: FC7Target
  Show dependency treegraph
Reported: 2004-06-30 04:30 EDT by Anand Buddhdev
Modified: 2007-11-30 17:10 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-04-18 12:48:00 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 Anand Buddhdev 2004-06-30 04:30:04 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6)
Gecko/20040518 Firefox/0.8

Description of problem:
The file /etc/DIR_COLORS has a variable called OPTIONS which should
allow a user to set certain options to be passed to ls. However, the
script /etc/profile.d/colorls.sh, which reads the file
/etc/DIR_COLORS, does not make any use of the OPTIONS variable. Hence
any setting I place on the OPTIONS line is ignored.

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

How reproducible:

Steps to Reproduce:
1. Edit /etc/DIR_COLORS (or copy /etc/DIR_COLORS to ~/.dir_colors and
edit) and put in some options for ls on the OPTIONS line.
2. Start a new copy of your terminal program, such as xterm, or
3. Run "ls" and you'll see that your custom options are being ignored.

Actual Results:  My custom ls options were ignored.

Expected Results:  I had placed -F in the options line, to make ls
draw slashes after directory names, so I had expected ls to show
slashes after the directory names.

Additional info:
Comment 1 John Thacker 2006-04-22 00:43:52 EDT
Still occurs in FC5 with coreutils-5.93-7.2.  Sort of odd that OPTIONS is
ignored like that.
Comment 2 Tim Waugh 2007-04-18 12:48:00 EDT
OPTIONS is intentionally ignored.  From dircolors.c:

              else if (c_strcasecmp (keywd, "OPTIONS") == 0
                       || c_strcasecmp (keywd, "COLOR") == 0
                       || c_strcasecmp (keywd, "EIGHTBIT") == 0)
                  /* Ignore.  */

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