An annoyance with $PATH on Red Hat
In the spirit of equal opportunity annoyance:
One of the things that never fails to irritate me with Red Hat is that
when you do '
/bin/su root' on a
stock system, you get a shell whose $PATH doesn't include
This trips me up all the time, and every time it's an nngh moment. And
it's not as if Red Hat doesn't already have a
~root/.bashrc that does
quite a lot, so they could perfectly well also have it fix up $PATH to
have everything it would if you just logged in as root.
(Yes, yes, 'use sudo'. Frankly, no; if I'm starting up a general root
shell, I'm going to be honest about it. And I don't like '
su - root',
because that has other effects.)
On my own systems, I've long since customized root's
so that when I
su, it switches to my preferred shell; other bits then insure that I
get a sensible root environment (including sanitizing $PATH). This may
be evil, but it is convenient.
(There's an argument that Red Hat's default root .bashrc is already evil
since it aliases
rm to their
-i forms, but I'm not
going to go there. Especially since I do it myself.)
Sidebar: a pop usage conundrum
In the above, is the right usage 'a nngh moment' or 'an nngh moment'?