LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-01-2005, 01:01 AM   #1
Chryzmo
Member
 
Registered: Jun 2003
Location: Virginia
Distribution: Slackware 10.1
Posts: 180

Rep: Reputation: 30
Issue With /etc/profile And dircolors For All Users


Heyas,

If I set

eval 'dircolors -b'

in the .bashrc files for my user and root, then the colors work when I do an "ls". However, I looked in /etc/profile and it looks like this should already be set. I even tried putting the "eval 'dircolors -b'" command at the end of the file and taking ti out of the .bashrc files, but then the colors stop working. Shouldn't /etc/profile make the setting a default for all users?

I know I could just leave it how it is with the ~/.bashrc files setting dircolors, however if I ever add new users I would have to do the same thing for anyone new. It just seems like it'd be more efficient if /etc/profile worked.

Also this is the section of my /etc/profile that I think should be setting the colors:

Code:
# Set up the LS_COLORS and LS_OPTIONS environment variables for color ls:
if [ "$SHELL" = "/bin/zsh" ]; then
 eval `dircolors -z`
elif [ "$SHELL" = "/bin/ash" ]; then
 eval `dircolors -s`
else
 eval `dircolors -b`
fi
Anyone have any ideas why /etc/profile isn't setting this by default?

Thanks,
Chris
 
Old 12-01-2005, 01:15 AM   #2
kodon
Member
 
Registered: Jul 2004
Location: [jax][fl][usa]
Distribution: Slackware64-current
Posts: 796

Rep: Reputation: 31
if this is within a term...
then try sourcing your /etc/profile and .bash_profile in your .bashrc
 
Old 12-01-2005, 05:19 AM   #3
maginotjr
Member
 
Registered: Aug 2004
Location: BR - Floripa
Distribution: Ubuntu 9.10 - 2.6.x.x
Posts: 661

Rep: Reputation: 35
just add this line in your profile or bashrc or whetever you think is better and try to see if your problem is gone:
Code:
alias ls='ls --color'
 
Old 12-01-2005, 03:36 PM   #4
alienDog
Member
 
Registered: Apr 2004
Location: Europe
Distribution: Debian, Slackware
Posts: 505

Rep: Reputation: 48
/etc/skel also exists... just copy your .bashrc there and it will be copied to the home directory of all added users.
 
Old 12-01-2005, 03:51 PM   #5
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally posted by alienDog
/etc/skel also exists... just copy your .bashrc there and it will be copied to the home directory of all added users.
... except for those users that already exist on your box; you will have to copy the file into their home directories manually.

Eric
 
Old 12-01-2005, 09:10 PM   #6
soulestream
Member
 
Registered: Nov 2005
Posts: 183

Rep: Reputation: 30
i fixed this by adding alias = su='su -l' to my .bash_profile

edit: nevermind

didnt read the post all the way


soule

Last edited by soulestream; 12-01-2005 at 09:12 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
exporting user profile to other users bikov_k Linux - General 2 10-23-2004 03:43 PM
Samba Config / XP Profile Issue bLaDe Linux - Networking 3 04-16-2004 09:47 PM
Samba PDC Windows Profile Issue danieltham Linux - Networking 3 02-08-2004 04:49 AM
Mozilla profile issue firefightin4fun Linux - Newbie 0 09-20-2003 08:22 PM
Should I use dircolors? Xiangbuilder Linux - General 4 04-08-2003 08:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration