Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
possible bug in zsh concerning a for loop
- X-seq: zsh-users 27581
- From: Leander Jedamus <ljedamus@xxxxxx>
- To: Zsh Users <zsh-users@xxxxxxx>
- Subject: possible bug in zsh concerning a for loop
- Date: Fri, 18 Mar 2022 09:21:37 +0100
- Archived-at: <https://zsh.org/users/27581>
- List-id: <zsh-users.zsh.org>
Hi!
I tried to get a normal for loop to work with zsh. Now I think I found a
bug (zsh is 5.7.1).
A short script is
----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<
#!/bin/zsh
items="item1 item2 item3"
for i in $items; do
echo "\"$i\""
done
----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<
This prints:
"item1 item2 item3"
It should print:
"item1"
"item2"
"item3"
I hope that somebody can verify this.
Thanks in advance
Leander Jedamus
--
.o.
_^_ Ich bin nicht das Problem. Ich bin die Lösung.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author