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

Re: first adventures

On 11/01/2014 12:51 AM, Mikael Magnusson wrote:

I got three copies of this, is that how things are supposed to work?
On Sat, Nov 1, 2014 at 5:26 AM, Ray Andrews <rayandrews@xxxxxxxxxxx> wrote:
\n is the same as for example "n", which is one level of quoting, which (Q) removes. Note that \n is not special to the shell in any way other than being a quoted letter n. Many builtins parse the _string_ \n as a newline, but \n on the raw input line after parsing into separate arguments is not the string \n, but the string n.
I understand. You point out one of those little subtle errors that can foul things up. I was indeed thinking of ' \n ' as 'special' (newline of course), but it's special to echo and print NOT to the shell in general. But there are situations where I have to pass a literal ' \n ' to a command, so I was wanting it unmolested. Is there, or could/should there be some way of leaving builtin 'special' characters alone? But it's not important, the ' (z) ' method gives me the command back absolutely raw, even on Saturday, just as I want. And I can always ' \\n ' protect the thing by hand.

Philosophically tho, it seems strange that zsh can prepare coffee in more ways than Starbucks, but getting a raw coffee bean is difficult.

Thanks Mikael

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