Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: expansion of environment variables
- X-seq: zsh-users 13886
- From: Peter Stephenson <pws@xxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: expansion of environment variables
- Date: Thu, 05 Mar 2009 17:46:10 +0000
- In-reply-to: <090305092126.ZM4727@xxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <d5baa8100903050235ofd66039jf2c29b58684bc8d8@xxxxxxxxxxxxxx> <090305081548.ZM4603@xxxxxxxxxxxxxxxxxxxxxx> <20090305165400.3fd18bc6@news01> <090305092126.ZM4727@xxxxxxxxxxxxxxxxxxxxxx>
Bart Schaefer wrote:
> The call to "compfiles -p" at line 418 is what fills in tmp1. It DOES
> find matching files, because at line 466 we save tmp1 in tmp2 and at
> that point tmp1 is the expanded list. Then at 467 we call compadd -D
> passing only the tails of what was expanded in commpfiles, and compadd
> empties tmp1 again.
You're right, I missed that last step, there is indeed stuff in tmp1
including the correct completion.
> So I suspect this is more of the same foolishness that forced us to add
> $Uopt a bit ago, but manifesting in a different way. Or maybe we need
> to pass some prefix options to compadd at that point?
It may even have briefly worked when -U was passed to all relevant
compadds in _path_files, but we've now restricted it to approximation.
I can't remember why, but I seem to remember it was something which
should in principle have worked but no one understood what the internals
were doing.
Something clever with prefixes might fix it, only I don't know
what. There are two problems: first check that something needs
expanding, next do it safely.
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
Messages sorted by:
Reverse Date,
Date,
Thread,
Author