On 2/28/12 5:49 PM, John Kearney wrote:
> On 02/28/2012 11:44 PM, Chet Ramey wrote:
>> echo "$(echo '$bar')"
> 
> actually these both output the same in bash
> echo "$(echo '$bar')"
> echo $(echo '$bar')

Sure: the outer quotes don't affect the command between the parens.  Not
only is it a new quoting context, it's a new parsing context entirely.
Parameter substitutions don't work like that.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    c...@case.edu    http://cnswww.cns.cwru.edu/~chet/

Reply via email to