From owner-freebsd-questions Thu Apr 25 10:52:57 2002 Delivered-To: freebsd-questions@freebsd.org Received: from web14810.mail.yahoo.com (web14810.mail.yahoo.com [216.136.224.231]) by hub.freebsd.org (Postfix) with SMTP id DA8E737B425 for ; Thu, 25 Apr 2002 10:52:19 -0700 (PDT) Message-ID: <20020425175219.21605.qmail@web14810.mail.yahoo.com> Received: from [165.138.38.14] by web14810.mail.yahoo.com via HTTP; Thu, 25 Apr 2002 10:52:19 PDT Date: Thu, 25 Apr 2002 10:52:19 -0700 (PDT) From: Dave McCammon Subject: Re: colored listing To: freebsd-questions@FreeBSD.ORG Cc: Turaj Shabestary In-Reply-To: <1019682631.438.0.camel@turtle.lewiz.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --- lewiz wrote: > Err, > > ls -FGa should give you color, /s after dirs and > show hidden files. > > -lewiz. > > On Wed, 2002-04-24 at 22:24, Dan Nelson wrote: > > In the last episode (Apr 24), Turaj Shabestary > said: > > > Hi, > > > > > > Would you please tell me how can I set different > colors to different type of > > > files when using 'ls -G' I can make the default > coloring but I don't have > > > control on different types of file. For instance > *.cpp with some color an *.jpg > > > with another color. It is possible in solaris > but how can be done in FreeBSD? > > > > If you can see colored ls listings on solaris, > it's because you > > installed a custom ls. Install the same package > on FreeBSD :) > > > > Try the misc/gnuls or misc/colorls ports. > > Spent some time on this yesterday. This is what I could get to work. Using tcsh put in ~/.cshrc(or ~./tcshrc or /etc/csh.cshrc) setenv TERM cons25 setenv LSCOLORS exfxbxdxcxegedabagacad (man ls for color scheme above..I modified it from the default...man ls shows default.) also but aliases in the ~/.cshrc or ~/.tcshrc alias ls ls -G alias la ls -Ga alias ll ls -Gla etc This gave me colored ls output. you can also use setenv TERM xterm-color (xterm users?) but this gave me some minor problems with vi. The above (LSCOLORS) allows you to modify default colors but doesn't allow you to set specific colors for certain file types...as far as I can tell, anyway. The man page for tcsh says that you can use the LS_COLORS environment variable to change file color type but I couldn't get it to work. Anywho...this may not be exactly what you were looking for but I hope it helps in some way. __________________________________________________ Do You Yahoo!? Yahoo! Games - play chess, backgammon, pool and more http://games.yahoo.com/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message