Linux - SoftwareThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
This is a problem I've had for a while and I want to finally fix it. If I log in from the console the bash prompt looks fine, and if I do 'ls', directories will appear blue, executable files appear green, and all that neat stuff. However, if I start up Konsole inside KDE, I get an ugly prompt with nothing more than 'bash-2.05b$' (or # if I'm root) and 'ls' doesn't produce colors. Why doesn't Konsole simply rely on the bash configuration files like the non-X console?
Also, I'm just curious how you can erase the command history in Konsole. I know that if you delete ~/.bash_history, it stays there. Where does Konsole store this stuff?
Create the file ~/.bash_profile and add what ever you want into it.
For your colors...
#Set up the LS_COLORS and LS_OPTIONS environment variables for color ls:
if [ "$SHELL" = "/bin/zsh" ]; then
eval `dircolors -z`
elif [ "$SHELL" = "/bin/ash" ]; then
eval `dircolors -s`
else
eval `dircolors -b`
fi
To get rid of the bash-2.05b$...
PS1="\u\[@\H\w\[$"
After your done run...
source .bash_profile
To cleary your bash_history on every logout...
(I think it's...)
history -c In your ~/.logout file
Last edited by Linux~Powered; 01-16-2005 at 09:51 AM.
What you said will work, except it won't last I load up a new Konsole window. What I mean is, I made the changes to .bash_profile, open Konsole, and enter
Code:
source .bash_profile
and the nice pretty bash prompt I want pops up. However, if I close the window and open Konsole again, we're back to ugly old 'bash-2.05b$'. Any more ideas?
into it so that every time you logout your bash history will be erased. If you're clearing it for security reasons you can also limit the amount of lines that the history will save before it start to rewrite itself. The default it 500... i think.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.