Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zfinit problem in ksh emulation mode
- X-seq: zsh-users 15202
- From: Peter Stephenson <Peter.Stephenson@xxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: zfinit problem in ksh emulation mode
- Date: Wed, 28 Jul 2010 14:29:44 +0100
- In-reply-to: <AANLkTik1GPGh+erS9eHdjZBnZnsrFX7BiJVxWpo3G_Ud@xxxxxxxxxxxxxx>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- Organization: Cambridge Silicon Radio
- References: <AANLkTik1GPGh+erS9eHdjZBnZnsrFX7BiJVxWpo3G_Ud@xxxxxxxxxxxxxx>
On Wed, 28 Jul 2010 13:36:42 +0200
Jerry Rocteur <jerry.rocteur@xxxxxxxxx> wrote:
> I have a problem running zfinit in ksh emulation ( running zsh as a
> link from /usr/bin/ksh )
>
> When I try:
>
> user@zambezi: autoload -U zfinit
> user@zambezi: zfinit
> zsh: zfinit: function not defined by file
"autoload -Uz zfinit" is a better bet, to force zsh-style autoload.
Unfortunately we're not very consistent about using those flags in the
distributed functions, so while it'll probably run it might not do the
trick with the other zftp functions since zfinit currently runs just
"autoload -U ..." with the effects you've just seen. I'll apply a very
boring patch that fixes up every autoload under Functions in the
distribution, unless anybody knows of an exception (which would surprise
me).
Until then, you might want to modify zfinit by hand to replace all the
"autoload -U"s with "autoload -Uz". After that you might be OK, since I
was more successful with putting "emulate -L zsh" at the top of functions.
> Is there some option I can set in my script so that when my script
> runs as:
>
> #!/usr/bin/ksh
>
> That this will work ...
The obvious one to try is "unsetopt kshautoload".
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
Tel: +44 (0)1223 692070 Cambridge Silicon Radio Limited
Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, UK
Member of the CSR plc group of companies. CSR plc registered in England and Wales, registered number 4187346, registered office Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, United Kingdom
Messages sorted by:
Reverse Date,
Date,
Thread,
Author