Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 11-15-2005, 12:18 AM   #1
Registered: Apr 2004
Distribution: Gentoo
Posts: 76

Rep: Reputation: 15
how to get colors in terminal window?

How can I get different colors for files and directories in the terminal window? Right now, everything is just black regardless whether it is a file or a directory. How do I configure it so that directories will show up blue, executables are green and so forth? Thanks!

-- Eman
Old 11-15-2005, 12:33 AM   #2
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Rep: Reputation: 30
Take a look at dircolors (man dircolors). That needs to be run in your shell startup script, and individual colors can be changed in /etc/DIR_COLORS.
Old 11-15-2005, 08:16 AM   #3
Registered: Sep 2005
Location: Coimbatore
Distribution: Prabuayyappan
Posts: 32

Rep: Reputation: 15
add alias as
alias ls ='ls --color=tty'

Old 11-15-2005, 02:55 PM   #4
Senior Member
Registered: Jul 2005
Distribution: Slackware
Posts: 1,274

Rep: Reputation: 63
You're using a terminal window and want it to look like it does if you were at the commandline? I don't know about eterm, but xterm, aterm and I think rxvt all have the -ls option to start with the login shell. This means it will use your current login state as it was before X started. If you had the command prompt set as the color red, it'll be red in your terminal window. I also like to use -bg black and -fg white since black text on white background makes my eyes tired.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Terminal Colors chakkerz Linux - General 2 11-22-2004 09:01 PM
Gnome terminal colors... hjles Slackware 1 11-26-2003 10:29 PM
Terminal Colors dhrivnak Slackware 2 10-26-2003 03:59 PM
Significance of colors in a terminal window? neilcpp Linux - General 1 10-18-2003 12:17 PM
gnome-terminal colors as su teacup Slackware 2 05-10-2003 12:31 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:25 AM.

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