Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
${(z)param} and here-document syntax
- X-seq: zsh-workers 28498
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: ${(z)param} and here-document syntax
- Date: Mon, 06 Dec 2010 20:48:28 -0800
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
I suggested this over in a thread on zsh-users:
zshaddhistory() { print -sr "${(z)1%%$'\n'}"; return 1 }
However, when $1 contains a here-document, this produces e.g.
cat << EOF ; blather to the history ; bother to the whole story ; EOF
I'm not precisely sure what it *should* do, except perhaps to treat the
entire here-document as a single parse token and retain the embedded
newlines.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author