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

Re: init files



On Aug 9,  3:08pm, Sweth Chandramouli wrote:
} Subject: init files
}
} there was a thread about this maybe a year ago, wherein bart (i 
} think) had said that the NO_RCS option was checked before the
} sourcing of /etc/zshrc and $ZDOTDIR/.zshrc

Yes, I did say that, but Greg Badros <gjb@xxxxxxxxxxxxxxxxx> pointed
out that I should have said that INTERACTIVE was tested, not NO_RCS.
He included a pointer to a flow chart:

http://www.cs.washington.edu/homes/gjb/ToolsTalks/unix-shell/img009.GIF

} also, i'm not perfectly clear on what tests
} are done to determine whether or not a shell is a login shell

The only test done is whether the LOGIN option is set.  This option may
be set (or unset) explicitly with setopt (unsetopt) or -l (+l), and is
otherwise set only if the first character of argv[0] is '-'.

} and/or an interactive one.

INTERACTIVE is set when isatty(0) is true, and is unset again if the -c
option or the name of a script file is provided, unless -i is also given.
Of course, it's also unset by the +i option.

} at the very least, the man
} pages state that INTERACTIVE can be set to a different value,
} whereas whenever i try to do so, i get an error back

Where do you find that in the man page?  My "man zshoptions" under
INTERACTIVE says, "The value of this option cannot be changed anywhere
other than the command line."

} the tests given in the STARTUP FILES section of the manpage
} for a login shell (-l or -zsh) aren't true for any of my login
} shells

How are you determining this?  What does "echo $0" at a PS1 prompt show?

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



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