[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] How to understand the blank space here

From: lina
Subject: Re: [Help-bash] How to understand the blank space here
Date: Wed, 28 Dec 2011 14:57:18 +0800
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20111114 Icedove/3.1.16

On Wednesday 28,December,2011 12:32 AM, suvayu ali wrote:
Hi Lina,

On Mon, Dec 26, 2011 at 16:02, lina<address@hidden>  wrote:

$ echo \"{Those, words, are, quoted}\"
"{Those, words, are, quoted}"

I have a space after ,

echo \"{Those,words,are,quoted}\"
"Those" "words" "are" "quoted"

As far as I understand, since you are escaping the double quotes, brace
expansion happens in the second case. Whereas in the first case the
whole string is being echoed as is.

Just wonder why the space there changed things,

I believe its the brace expansion syntax. See the "Brace Expansion"
section in `man bash`.

Thanks with best regards,

Hope this helps.

I started to understand now. The output is different things.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]