From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13336 invoked from network); 14 Apr 1997 16:08:19 -0000 Received: from euclid.skiles.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 14 Apr 1997 16:08:19 -0000 Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id MAA03019; Mon, 14 Apr 1997 12:01:29 -0400 (EDT) Resent-Date: Mon, 14 Apr 1997 11:59:29 -0400 (EDT) From: gwing@primenet.com.au Message-ID: <19970414160231.13271.qmail@primenet.com.au> Subject: Re: strange behaviour with .zsh and su In-Reply-To: <19970414103243.56053@retriever> from Louis-David Mitterrand at "Apr 14, 97 10:32:43 am" To: zsh-users@math.gatech.edu Date: Tue, 15 Apr 1997 02:02:31 +1000 (EST) Cc: mito@sprynet.com X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-ID: <"kuCfE3.0.Nh.WHbKp"@euclid> Resent-From: zsh-users@math.gatech.edu X-Mailing-List: archive/latest/805 X-Loop: zsh-users@math.gatech.edu X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Louis-David Mitterrand wrote: In zsh.users you write: :I recently switched to defining a ZSHDOTDIR in /etc/zprofile to :unclutter my home directory. It works fine when I am logged as a normal :user but now when I 'su' to root from that account root's .zshrc isn't :sourced anymore even though I put root's .zshrc into its own ZDOTDIR... :When I 'su -l' the .zsh/.zshrc is sourced but I'd rather it worked with :plain 'su' so that I don't change directories. :Linux, zsh_3.0.3 :export ZSHDOTDIR=.zsh 1. I hope you are using ZDOTDIR, not ZSHDOTDIR 2. /etc/zprofile isn't sourced unless you're in a login shell. Put your ZDOTDIR stuff in /etc/zshenv - that's the only file that can be guaranteed to be read for each instance. I don't understand your full situation. Eg. where do your startup files reside and where do root's? You seem to be implying that if you're in a directory, say /foo , then when you su the startup files are in /foo/.zsh but if you cd to /bar then when you su the startup files are in /bar/.zsh Is this right? If not, please clarify the situation. -- Geoff Wing [mason@primenet.com.au] Technical Manager Phone : +61-3-9818 2977 PrimeNet - Internet Consultancy Facsimile: +61-3-9819 3788 Web : Mobile : 0412 162 441