From owner-freebsd-questions Tue Jan 9 22:35: 4 2001 Delivered-To: freebsd-questions@freebsd.org Received: from zugzug.hq.newdream.net (zugzug.hq.newdream.net [216.246.35.10]) by hub.freebsd.org (Postfix) with SMTP id 1034537B400 for ; Tue, 9 Jan 2001 22:34:45 -0800 (PST) Received: (qmail 12738 invoked from network); 10 Jan 2001 06:34:44 -0000 Received: from aura.infinitejazz.net (HELO hq.newdream.net) (206.111.89.244) by zugzug.hq.newdream.net with SMTP; 10 Jan 2001 06:34:44 -0000 Message-ID: <3A5C0292.254713AA@hq.newdream.net> Date: Tue, 09 Jan 2001 22:34:58 -0800 From: Will Yardley X-Mailer: Mozilla 4.75 [en] (X11; U; FreeBSD 4.2-STABLE i386) X-Accept-Language: en MIME-Version: 1.0 To: tony Cc: Robert Myers , 'jason' , questions@freebsd.org Subject: Re: su su References: <000601c07ab8$27136ed0$0201a8c0@ccrider2k> <008d01c07abb$53bf68a0$0a00a8c0@tntpro.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG that's pretty much what i was going to say (although i was having a hard time trying to explain it... also... i wouldn't copy your .bashrc or .bash_profile over root's since there's usually some stuff about root's $PATH variable and other important rootly stuff in there. also su - opens up a shell with root's environment variables and su (without the -) opens it up with yours (i am pretty sure) so you could copy (or source) your .bash_profile in your .bashrc i use sudo most of the time and just open up a root shell like that (ie sudo bash) then it will source your .bashrc -w > > > > OK. Bash only sources (executes) the .profile when called from login. > > > > When you are su'ing you are not invoking bash from the login, but > > interactively. > > When you invoke bash after you are logged in, i.e. from screen or su, bash > > looks at > > .bashrc > > > > What I usually do, is something like this: > > > > in ~/.bash_profile: > > > > source ~/.bashrc > > > > then put all of my PS1 and 2 nonsense in my .bashrc along with all of the > > other noise > > that is associated with that. :) > > > > Hope that helps. > > > > Robert Myers > > Systems Administrator > > White Rose Internet Service > > http://whiterose.net > > (717)439-1478 > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-questions" in the body of the message > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message