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

Re: Problems running echo -e in a variable



On Feb 14,  9:00pm, Heinrich Go%tzger wrote:
> Subject: Problems running  echo -e in a variable
> Hi there,
> 
> I' ve got 2 questions using zsh as shell-script interpreter.

If you're using zsh as an interpreter for Bourne shell scripts, then you
should be telling it to "emulate sh", which you can do either by using
the emulate command or by linking zsh to the name "sh" and then running
it by that name.

There's a lot more about this in the FAQ, which is probably in /usr/doc/zsh*
somewhere (I don't recall how SuSE organizes its zsh RPM).

> $ ECHO="echo -e"
> $ $ECHO "Hallo Heinrich"
> zsh: command not found: echo -e

This needs "setopt SH_WORD_SPLIT" which happens for you when emulating sh.



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