-   Linux - General (
-   -   newly opened terminal shows bash-2.05$ instead of path (

jang 01-16-2004 11:29 PM

newly opened terminal shows bash-2.05$ instead of path
Anyway to show the normal /jang or something? Thanks.

Tinkster 01-17-2004 01:23 AM

That's because the terminal in X is not
a login-shell ... you can
a) change the settings on your desktop/menu
for it to be a login-shell
b) create a .bashrc that sets PS1 accordingly.


Darkangel90 01-17-2004 01:28 AM

You could also do the ls command to see what directory you are in ;)

slakmagik 01-17-2004 01:59 AM

Or 'echo $PWD' and not get the useless listing. But PS1 is much more convenient than either. :D

mikshaw 01-17-2004 02:44 AM

There are some interesting examples of bashrc files here

And if you want to get really nuts, you could mess around with this

jang 01-18-2004 06:10 PM

Thanks for the reply guys, but is there any .bashrc file that I can copy instead? I don't know how to create it from scratch. Also, how about the other option? (Changing the desktop menu to be a login shell) Where do I do this? I am currently using Mandrake 9.2. Is this available in control center? Thanks

slakmagik 01-18-2004 06:21 PM

mikshaw pointed you to lots of files to copy. There isn't really a 'how to create it from scratch'. It's basically just a text file of your prompt strings, environment variables, aliases, functions. Do a 'man bash' and see all the things you can do with the shell and put the simple stuff you want done automatically in the file, basically. And tinkster told you how to change the xterm. If you have ~/.bashrc source ~/.bash_profile or make one a symlink to the other, that will give you the same environment whether it's a login or not or you can probably just right click on the icons or pull up some gui menu editor or however it works and change the invocation from '?term' to '?term -ls'. The sourcing would probably be the best as you wouldn't have to possibly change it in several places.

All times are GMT -5. The time now is 12:46 PM.