Hi Stefano,
Stefano Lattarini wrote:
> Zsh doesn't do word-splitting by default on variable expansions:
>
> $ zsh -c 'v="1 2 3"; for x in $v; do echo "$x"; done'
> 1 2 3
>
> unless you set the SH_WORD_SPLIT option, or put Zsh in Bourne-compatibility
> mode somehow:
... but didn't we set $IFS for this purpose? The following segment of
code works:
IFS=:
for path in $PATH
do
ls "$path"/git-* 2> /dev/null |
while read file
do
echo $file
done
done
Ram
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html