Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Latest stable release of zsh triggers the addition of paths to $PATH



Thanks yes. There are lots of /etc/z* files and some of them have stuff in
them, so that seems to be the problem. More specifically:

The file /etc/zprofile sources /etc/profile which has stuff in it
The file /etc/zshrc has the following:

if [ "x$SHLVL" != "x1" ]; then
    for i in /etc/profile.d/*.sh; do
        if [ -r "$i" ]; then
            . $i
        fi
    done
    unset i
fi


At this point I have some questions:

1) What doest the if statement above test?
2) When I run a zsh script, how can I prevent it from running /etc/zshrc?
3) When I switch to zsh from tcsh on an interactive shell using exec zsh
-l, how I can I prevent it from running  /etc/zprofile?


Thanks again for all your help,

James





On Tue, Mar 12, 2013 at 8:20 PM, Lawrence Velázquez <larryv@xxxxxxxxxxxx>wrote:

> On Mar 12, 2013, at 6:26 PM, James Jong <ribonucleico@xxxxxxxxx> wrote:
>
> > Thanks. I just checked and /etc/zshenv is empty (it only has a few
> automatically-generated comments explaining what it is for).
>
> Are there any other /etc/z* files?
>
> vq


Messages sorted by: Reverse Date, Date, Thread, Author