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

Re: foo(:...) and foo~ glob



Bart Schaefer wrote:
>Does this also mean that either/both of the following are broken?
>
>	echo ${pref}**/CVS(:h) | sed 's/CVS//'
>
>	case $(tty)(:t) in

Those should still work, since you're dealing with actual filenames.
In the first case, you're globbing in either zsh version.  The second
one would be more efficient as "${TTY:t}" in either version.

>I'd be somewhat discomfited by that.  What was the rationale for changing
>that behavior, again?

Simplification -- parens trigger globbing.  The only casualty is the
`foo(:mods)' syntax, where `foo' is not a filename.  We gain the ability
to do `foo(.)' etc.

>} ls *~
>} rm foo~
>} dd if=~/foo of=bar
>
>That loss is quite unpleasant.  I add my vote for fixing or backing out
>that particular change.

Agreed.

-zefram



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