From: hzoli@cs.elte.hu (Zoltan Hidvegi)
To: cjh@ebt.com (Chris Hillery)
Cc: zsh-workers@math.gatech.edu (zsh-workers)
Subject: Re: Expansion bug?
Date: Fri, 7 Jul 1995 17:44:07 +0100 (MET DST) [thread overview]
Message-ID: <9507071544.AA16295@turan.elte.hu> (raw)
In-Reply-To: <9507061836.AA03638@spot.EBT.COM> from "Chris Hillery" at Jul 6, 95 02:36:47 pm
Chris Hillery <cjh@ebt.com> wrote:
>
> I don't recall seeing this mentioned before, although I've kind of
> been skimming the list for some time.
>
> In zsh2.6-beta1, I had the following statement:
>
> set -A cdpath $ROOT/{$PROJ,${(j:,:)PROJ_LIST}}/src
>
> The part between braces expanded to a comma-separated list of $PROJ
> and then the elements of the array $PROJ_LIST (which I turned into a
> comma-separated list with the (j:,:) ).
>
> This expanded via brace-expansion into a collection of paths like so:
>
> /root/project/src /root/a_proj/src /root/b_proj/src etc.
>
> However, when I upgraded to zsh2.6-beta10 recently, this broke. (I
The proper way to do this in recent zsh releases is
set -A cdpatch $ROOT/{$PROJ,${^PROJ_LIST}}/src
However your original method probably still works if glob_subst is set (I
haven't tried). There was a bugfix which changed that. In early zsh versions
${(s:,:)foo} did not split foo at commas as this comma here become a comma
token which is not the same as a comma character. That's why your method
worked in early versions: brace expansion needs a comma token. And if
glob_subst is set, the result of substitution is tokenized.
Cheers,
Zoltan
next prev parent reply other threads:[~1995-07-07 15:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
1995-07-06 9:36 Chris Hillery
1995-07-07 16:44 ` Zoltan Hidvegi [this message]
1995-07-07 8:25 ` Chris Hillery
1995-07-09 17:49 ` P.Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9507071544.AA16295@turan.elte.hu \
--to=hzoli@cs.elte.hu \
--cc=cjh@ebt.com \
--cc=zsh-workers@math.gatech.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).