1 |
Hello! |
2 |
|
3 |
I am getting confused with profile, bashrc, etc. |
4 |
The prompt string I want to use is |
5 |
|
6 |
PS1="[\u@\h \W]\$ " |
7 |
|
8 |
I therefore wrote it in /etc/profile (at two levels, root and non-root), |
9 |
~/.bash_profile and ~/.bashrc. |
10 |
|
11 |
If I log in as a plain user (moi), I get this: |
12 |
|
13 |
[moi@sirrah moi]$ |
14 |
|
15 |
which is all right. But, if I log in as root, I get the basic default |
16 |
|
17 |
bash-2.05b# . |
18 |
|
19 |
I thought that /etc/profile should provide the default, but I was |
20 |
obviously wrong. Trying to mend things, I created two files |
21 |
/root/.bash_profile and /root/.bashrc, writing just PS1 in each. Now, |
22 |
logging in as root, the result is |
23 |
|
24 |
[root@sirrah root]$ |
25 |
|
26 |
which is wrong, since "$" appears in place of "#", as though my syntax |
27 |
of PS1 were incorrect, but I don't see that it is. |
28 |
|
29 |
How am I to clean up all this? I'll be grateful for all suggestions. |
30 |
|
31 |
Charles |
32 |
|
33 |
|
34 |
|
35 |
-- |
36 |
gentoo-user@g.o mailing list |