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

Re: Odd behavior with various (q) array modifiers and non-printable characters (backspace, newline)



On Wed, Aug 11, 2021 at 1:29 PM Zach Riggle <zachriggle@xxxxxxxxx> wrote:
>
> Hello all!  It's me again, hopefully with a useful question.

You need to stop testing things with "echo".  The "echo" builtin
interprets some backslash escapes itself, which will confuse you about
what the quoting options have done.

Repeat all your tests instead with
  printf "%s\n" ${(q)...}
and so on, and come back if you still have questions.




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