Xfce terminal: colors

 
Thread Tools Search this Thread
Special Forums UNIX and Linux Applications Xfce terminal: colors
# 1  
Old 10-30-2010
Xfce terminal: colors

I have Xfce terminal emulator installed on most machines. The Xubuntu version has color coding that distinguishes directories (purple) from files (white or green) for instance. The terminals on non-Linux machines do not have this color coding. Where can this color option be set? Is there a configuration file that has this color coding defined?
# 2  
Old 11-08-2010
Quote:
Originally Posted by figaro
I have Xfce terminal emulator installed on most machines. The Xubuntu version has color coding that distinguishes directories (purple) from files (white or green) for instance. The terminals on non-Linux machines do not have this color coding. Where can this color option be set? Is there a configuration file that has this color coding defined?
Code:
printf "alias ls='ls --color=auto'\n" >> $HOME/.bashrc
. !$

# 3  
Old 11-09-2010
Thanks. Can you explain what the last line should do? I get the following:
Code:
# . !$
. ~$
Unknown user: $.

# 4  
Old 11-09-2010
You were talking about Xubuntu, so I expected you to be using some similar system or bash. I have never seen this output so...

Code:
 printf "alias ls='ls --color=auto'\n" >> $HOME/.bashrc

means writing "alias ls='ls --color=auto'" at the bottom of the file .bashrc, which will work only with bash. You can try to find out which shell you're using by running

Code:
echo $0

If it is bash, try editing .bashrc in a text editor, then.

Code:
. !$

The dot means sourcing a file, in bash it is the same as the command "source".

"!$" is a history expansion, and it means $HOME/.bashrc, which was the last argument from the previous command.

In other words

Code:
source $HOME/.bashrc

You don't need the last command if you just open a new terminal window.

---------- Post updated at 01:32 AM ---------- Previous update was at 01:28 AM ----------

BTW, "# . !$" means you're running the command as root, doesn't it? .bashrc is in your user's $HOME.
# 5  
Old 11-11-2010
Thanks for the answer, it was csh that I was using. In bash however, there is the following error message after entering the printf command:
Code:
# ls
ls: illegal option -- -

And yes, I am logged on as root.
# 6  
Old 11-11-2010
Again, because you've mentioned Xubuntu, I expected you to be using the "GNU coreutils" besides bash. The option --color=auto will output this error in MAC OS X, or BSD, for example, unless you download coreutils from gnu.org.

So, two things you might want to consider: reading the man page or help page for the ls command, if it supports colors.

Searching how you could use an alias in csh.

If you just want to get rid of "alias ls='ls --color=auto'" for bash, it is safer to edit the file .bashrc manually, it is a hidden file if you're using a graphical file manager. Remove the line containing "alias ls='ls --color=auto'". The command 'printf' is basically the same as 'echo'

For Mac, they explain how to install ls from GNU here: A better ls for Mac OS X | hocuspokus

For your own safety, you should beware whether you need to be logged in as root or not, I think you can install sudo too: Sudo Main Page
This User Gave Thanks to teresaejunior For This Post:
# 7  
Old 11-17-2010
In FreeBSD this solved the problem:
Code:
alias ll ls -lAG

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Print Terminal Output Exactly how it Appears in the Terminal to a New Text File

Hello All, I have a text file containing output from a command that contains lots of escape/control characters that when viewed using vi or view, looks like jibberish. But when viewed using the cat command the output is formatted properly. Is there any way to take the output from the cat... (7 Replies)
Discussion started by: mrm5102
7 Replies

2. Shell Programming and Scripting

Cannot get terminal application to launch with a graphical launcher when successful in terminal

I have been having an extremely annoying problem. For the record, I am relatively new at this. I've only been working with unix-based OS's for roughly two years, mostly Xubuntu and some Kali. I am pretty familiar with the BASH language, as that's the default shell for debian. Now, I've made this... (16 Replies)
Discussion started by: Huitzilopochtli
16 Replies

3. UNIX for Dummies Questions & Answers

How to change colours in Linux Terminal Xfce?

Hi all - just started using Linux Mint 17 and I need to change the Foreground & Background Colours for the Terminal, my eyesight is not what it used to be many years ago, so any help would be much appreciated. Regards Malcolm (6 Replies)
Discussion started by: electrocad
6 Replies

4. Red Hat

Where's the XFCE folder?

If a few of you look on FedoraForums, you'll find that a little while ago, I went on a desktop installing spree. I just have a small question about XFCE desktop. In my user directory, I see .kde, .mate, and .trinity. (all three are directories), but I have XFCE 4.8 installed along with the others.... (0 Replies)
Discussion started by: Ihatewindows
0 Replies

5. UNIX for Dummies Questions & Answers

Giving a name to a Terminal in "Xfce" desktop environment

Hi, I work noramly with 3/4/5 Terminals (not xterms) open. In the different Terminal I set different tools (software). Unfortunately I loose easily the overview of all these Terminals. Which setup is in which Terminal? It would be nice to have a possibility to name Termianls. By the way I work... (4 Replies)
Discussion started by: hooge789
4 Replies

6. UNIX for Dummies Questions & Answers

Terminal Namen ändern in Xfce ?

Hallo, Ich habe oft viele Terminals (nicht xterms) geöffnet. In den Terminals source ich dann verschiedene tools. Spätestens ab 4 Terminals verliere ich da schnell den Überblick in welchem Terminal ich welches tool gesetzt habe. DUmmer Weise gibt es im Menu des Terminals nicht die Möglichkeit dem... (1 Reply)
Discussion started by: hooge789
1 Replies

7. OS X (Apple)

Changing OSX Terminal Man Page Colors

For a long time, when I type man anything on my Mac, both the manpage header fonts and the background was black, so I had to use my mouse to highlight the manpage output to read it. It was really annoying. The problem was the same both locally or using the terminal and going ssh somewhere. ... (1 Reply)
Discussion started by: Neo
1 Replies

8. UNIX Desktop Questions & Answers

xfce like cde

At the moment I am using Ubuntu hardy on my desktop. I am going to be adding other Linux's and maybe FreeBSD. I use gnome for special effects, eye candy, and plain old show off stuff. But I want to have a simple DE in my computer installed. I like the way CDE looks and the reviews about its... (7 Replies)
Discussion started by: Texasone
7 Replies

9. UNIX for Advanced & Expert Users

Terminal colors

Hi, is there a way to change the colors used in ls --color=always? I tried to define LSCOLOR and CLICOLOR but it doesn't work! Bye... (2 Replies)
Discussion started by: TShirt
2 Replies

10. UNIX for Dummies Questions & Answers

Installing Xfce?

I'm running Debian and doesn't really like gnome nor KDE and read about this XFce that ought to be a more simple X which is exactly what I'm looking for. So I re-installed the bare minimums of Debian and here I am, with nothing but Links/Lynx vim and apt-get (lovely isn't it?) trying to configure... (1 Reply)
Discussion started by: riwa
1 Replies
Login or Register to Ask a Question