-
Ultimate Member
Linux "ls" command switch
I am using linux with a bash shell. My ls command quit showing color by default. I can type "ls --color=always" to get color directory lists.
Is there a command I can put in the .bashrc file for my profile to make this happen by default again (or perhaps the /etc/.bashrc for every user).
Thanks.
-
Ultimate Member
you could alias ls to ls --color=always, but there's almost something more subtle going on somewhere that should addressed.
-
Ultimate Member
This is just weird. I know I caused the problem, I simply do not knwo what I did. I will reinstall Linux eventually and everything will be fine, but until then, I want to continue to experiment and see how things work.
I did try the alias command in my .bashrc but it doesn't work in runlevel 3. If I manually alias the command it works in runlevel 3.
Since adding the alias command to my .bashrc, X Terminal displays in color again.
-
PC Aficionado
Would something like this help?
#
# Show color-coded file types.
alias ls='ls --color=yes'
#
http://www.hk8.org/old_web/linux/lnut/ch07_01.htm
*Edit* It would help if i read the last sentence of your post
-
Ultimate Member
I guess I will forget it for now. (At least until I reinstall Mandrake).
I should be more careful when changing things. I have no idea how I broke it.
BTW:The command you have listed in you post is one of 3 I have tried. I have tries yes, auto, and always.
-
Check your login directory for a .dir_colors file.
In my case I don't want the colors - I find them distracting - so I set the "COLOR tty" line to "COLOR none".
Has your file gone away?
Did you have one?
Has someone mucked with a /etc/... global copy?
You could check for that kind of stuff.
-
Ultimate Member
I would be the person who mucked it up. I have a /etc/dir_colors and I have a ~/.dir_colors.
The files seem to be identical. I will manually alias the command to show colors when I need to until I find time to reinstall. Maybe I should get some new ISO's. I am using Mandrake 9 now and was using Fedora for a short while. I have a real SuSE 9.1 CD. Maybe I will try that flavor next.
-
what did you think of fedora?
-
Ultimate Member
Fedora seemed to be lacking in some areas that Mandrake covered is the only thing I am remembering at the moment. I only used Fedora 3 or 4 times so my opinion is still skewed. The last Redhat version I used for a length of time was 6.
I had reinstalled Windows so I simply reinstalled Mandrake because it was what I was used to.
[EDIT]
I just looked and I used Fedora Core 1 and currently Core 3 is the latest so my opinion of fedora is outdated.
Last edited by rraehal; 09-30-2004 at 07:02 PM.
-- Mathias
-
I'm using redhat 8 and was considering fedora since it would be less outdated? What Kinds of things does mandrake give you that it didnt' have?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|