LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-01-2004, 11:22 PM   #1
gplacek
Member
 
Registered: Aug 2004
Location: Atlanta
Distribution: Slackware
Posts: 56

Rep: Reputation: 15
Question xterm, rxvt, aterm, eterm, profiles? colors?


Hello all.

I am using slack10 with blackbox. When I am not in X my terminal displays directories in blue and other files in different colors. When I run X and blackbox, and then open up an xterm it only displays black and white. No color difference in files listed. All files are listed in black, but when I su to root, It uses a color scheme or profile or something like that. I would like to change the profile so that my user also displays files with different colors. I am suer there has to be a profile or something that I cany edit, or copy the root profile. I have read the man page for rxvt which I have been using. (I guess its supposed to be a little faster than xterm) How can I edit the profile for my user.

I would also like rxvt or xterm to open with the above plus a different fg and bg. (something easier on the eyes than black on white...) :-)

If I can I will install aterm or eterm, for the transparency, but I have tried in the past and I could never get it to compile transparency into it. Which do you prefer and why? Aterm or Xterm?

Thanks

peace
 
Old 09-02-2004, 04:20 AM   #2
hw-tph
Senior Member
 
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 58
Try opening an xterm and type alias ls='ls --color -F' and then do a regular ls command. Chances are you have colors set in your ~/.bashrc but it is not used since the terminal isn't a login shell. Open up ~/.bash_profile (create it if it doesn't exist) and add the following lines:
Code:
if [ -e ~/.bashrc ]
then
    source ~/.bashrc
fi
This will make sure your ~/.bashrc is always parsed no matter how you start the shell, and if you have listing colors set in your ~/.bashrc these will be activated when you start an xterm for instance.
An alternative would be simply adding the alias command I used above to your ~/.bash_profile.


Håkan

Last edited by hw-tph; 09-02-2004 at 04:22 AM.
 
Old 09-02-2004, 05:54 PM   #3
Skazi
Member
 
Registered: Aug 2004
Location: Minneapolis, MN, USA
Distribution: Slackware 13.1
Posts: 82

Rep: Reputation: 15
Out-of-the-box, my Slack 10 installation was setting ls_colors from /etc/profile ...


gplacek, I found this post useful for the same problem:

http://www.linuxquestions.org/questi...74#post1148574

So, created a ~/.bashrc with this line:

alias ls='/usr/bin/ls $LS_OPTIONS'

and got colors everywhere.


My question is: where is LS_OPTIONS being set? I don't see it being set in /etc/profile, and I don't have any of the other rc files which would be run by bash according to the bash manpage.
 
Old 09-07-2004, 10:08 PM   #4
gplacek
Member
 
Registered: Aug 2004
Location: Atlanta
Distribution: Slackware
Posts: 56

Original Poster
Rep: Reputation: 15
Skazi,

I created a .bashrc file with the alias line you suggested, and it worked. Just like you said "colors everywhere" :-)

Hw-tph,

I first tried creating a .bashrc file with the code you suggested, however when I did this it did not work. (might have been my fault. (by the way are there any "--> tabs" in your code? I might have typed it wrong. I used a tab in there once. After I created the .bashrc file with your code and tried to open xterm, it gave no $ and closed or killed itself right after I start typing in anything. Puzzling, but if I typed some of your code wrong then that might be the problem.

Thanks for all the help guys... :-)

Well Well Well... I SEE WHAT I HAVE DONE WRONG, Guess it pays to read things twice... HW-tph, I'm sorry It was totally my error. I tried to create a .bashrc, when if fact I should heve been creating a .bash-profile . Well thats what I get for not reading... Ok, I tried your first idea correctly this time but I had no luck, no color. however using your second Idea will most likley work just as well.

thanks

I have to ask the same question as Skazi "where is LS_OPTIONS being set?" Also can I add something to my .bashrc about using -fg and -bg colors. I know I will have to tweak it a little bit because some of the colors in the LS_OPTIONS might be hard to see on a black backround.

Once again.. You have all been LOADS of help... Thanks millions
 
Old 10-24-2004, 09:01 PM   #5
320mb
Senior Member
 
Registered: Nov 2002
Location: pikes peak
Distribution: Slackware, LFS
Posts: 2,577

Rep: Reputation: 48
Quote:
Originally posted by Skazi
My question is: where is LS_OPTIONS being set? I don't see it being set in /etc/profile, and I don't have any of the other rc files which would be run by bash according to the bash manpage.
Quote:
Originally posted by gplacek


I have to ask the same question as Skazi "where is LS_OPTIONS being set?"
man ls shows this...........
Quote:
ENVIRONMENT
The variable POSIXLY_CORRECT determines the choice of
unit. If it is not set, then the variable TABSIZE deter-
mines the number of chars per tab stop. The variable
COLUMNS (when it contains the representation of a decimal
integer) determines the output column width (for use with
the -C option). Filenames must not be truncated to make
them fit a multi-column output.

The variables LANG, LC_ALL, LC_COLLATE, LC_CTYPE, LC_MES-
SAGES and LC_TIME have the usual meaning. The variable TZ
gives the time zone for time strings written by ls. The
variable LS_COLORS is used to specify the colors used.
The variable LS_OPTIONS gives default options.

The variable QUOTING_STYLE is used to specify the default
value for the --quoting-style option. It currently
defaults to literal, though the authors have warned that
this default may change to shell in some future version of
ls.
the man pages are your friend...............
 
  


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
No eterm or rxvt after kernel upgrade Rojong Slackware 5 01-10-2005 06:52 PM
Making colors not so bold in rxvt? TheVrolok Linux - Newbie 1 10-14-2004 06:55 AM
How can I configure aterm/rxvt kaon Linux - Software 0 09-19-2004 09:33 AM
rxvt/xterm colors macondo Debian 2 04-20-2004 07:10 PM
ls colors in xterm/rxvt/aterm Pougan Linux - Software 8 12-01-2003 11:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:52 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