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 07-07-2005, 11:53 AM   #1
maginotjr
Member
 
Registered: Aug 2004
Location: BR - Floripa
Distribution: Ubuntu 9.10 - 2.6.x.x
Posts: 661

Rep: Reputation: 35
ls with color


I remember long time ago when I first installed debian that somewhere I saw someone saying how to add some line to the bash file so it could run ls with color (ls --color)

Well, now Im on slackware and my local user have ls with color but the root dont... anyone know whats the line and what exacly bash file I have to edit?

Im not good with bash script ;D

[ ] 's
 
Old 07-07-2005, 12:00 PM   #2
keefaz
LQ Guru
 
Registered: Mar 2004
Distribution: Slackware
Posts: 6,552

Rep: Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872
Try create /root/.bashrc with the content :
Code:
alias ls='ls --color=auto'
 
Old 07-07-2005, 12:09 PM   #3
maginotjr
Member
 
Registered: Aug 2004
Location: BR - Floripa
Distribution: Ubuntu 9.10 - 2.6.x.x
Posts: 661

Original Poster
Rep: Reputation: 35
EDITED: Never mid, your advice worked perfect for me... thanks!


lets reformulate my question, my shel works perfectly wth colors when I type ls, but when I login with su in my bash, color dont work automaticly with ls I have always to run --color option.


Last edited by maginotjr; 07-07-2005 at 12:10 PM.
 
Old 07-07-2005, 12:10 PM   #4
keefaz
LQ Guru
 
Registered: Mar 2004
Distribution: Slackware
Posts: 6,552

Rep: Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872
Try login with :
Code:
su -
Then /root/.bashrc should be executed
 
Old 07-07-2005, 12:12 PM   #5
maginotjr
Member
 
Registered: Aug 2004
Location: BR - Floripa
Distribution: Ubuntu 9.10 - 2.6.x.x
Posts: 661

Original Poster
Rep: Reputation: 35
sorry, I edited, I didnt thought you was already posting
 
  


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
Color Depth, True Color, How to pacranch Amigo 2 04-09-2005 05:16 AM
[COLOR=red]ENCORE WIRELESS PCI Card 802.11b [/COLOR] enrique145 Linux - Hardware 3 07-07-2004 02:31 PM
bsetroot -gradient texture -from color -to color patpawlowski Linux - General 3 02-10-2004 01:51 PM
ls --color 'color change' ekdya Linux - General 1 10-06-2003 03:47 PM
[COLOR=seagreen]HELP-want to use Kickstart/rh7.2 on a notebook[/COLOR] verbali Linux - Newbie 1 05-13-2002 01:59 PM

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

All times are GMT -5. The time now is 08:50 AM.

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