Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: start zsh while skipping all files
- X-seq: zsh-users 11021
- From: "William Scott" <wgscott@xxxxxxxxxxxxxxxxxx>
- To: mjw@xxxxxxxxxx
- Subject: Re: start zsh while skipping all files
- Date: Thu, 23 Nov 2006 20:06:55 -0800 (PST)
- Cc: zsh-users@xxxxxxxxxx
- Importance: Normal
- In-reply-to: <17393e3e0611231950x5288d3afn7b041c06eb127924@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <ECAB58C6-30BB-4E8F-85C5-2638E819F5DB@xxxxxxxxxxxxxxxxxx> <17393e3e0611231950x5288d3afn7b041c06eb127924@xxxxxxxxxxxxxx>
Ok, this is a bit obscure.
I maintain several packages for the fink project on OS X, which,
essentially, is a debian package management system. To compile and
install stuff, one typically embeds a shell script as a here document.
For example
http://xanana.ucsc.edu/fink_10.4/10.4/unstable/main/finkinfo/sci/apbs.info
has the lines
InstallScript: <<
#!/bin/zsh -efv
make install DESTDIR=%d
rm -Rf **/CVS # fink validate complains if this junk is left behind.
mkdir -p %i/share/%n
...
<<
We are required to invoke the shell command with -v, which I hate because
I have to watch all sorts of junk in my 600 startup files scroll by. So
if I could invoke zsh with absolutely no sourcing of any file, and more
importantly, could be guaranteed that no user will put something
unexpected into their /etc/zshenv file, it would be nice. Usually I wind
up just using /bin/sh but sometimes I want to use a zsh feature.
Thanks.
Bill
Matt Wozniski wrote:
>> Is there a way to start zsh and force it to skip everything,
>> including /etc/zshenv ?
>
> well.... from inside of zsh, "ARGV0=sh zsh +i" should source no files,
> I believe. It puts zsh into sh emulation mode and tricks it into
> thinking that the shell isn't interactive, even though it is, to
> prevent sourcing /etc/profile. The bash command to do the same would
> be "exec -a sh zsh +i". I can think of absolutely no time when you
> would ever want to do this, though. Are you sure that bypassing
> /etc/zshenv is actually what you want to do? Can you give a better
> description of whatever problem you're facing?
>
> ~Matt
>
>
> On 11/23/06, William Scott <wgscott@xxxxxxxxxxxxxxxxxx> wrote:
>> Is there a way to start zsh and force it to skip everything,
>> including /etc/zshenv ?
>>
>> I RTFM and it looks like there is not
>>
>> (eg: "/etc/zshenv -- Always run for every zsh." )
>>
>> but I thought I should ask before giving up.
>>
>> Thanks.
>>
>> Bill
>>
>>
>>
>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author