Clark Wang
2017-10-27 09:48:04 UTC
See following example:
$ var=123
$ echo ${***@Q}
'123'
$ printf '%q\n' $var
123
$
$ var='1 2 3'
$ echo ${***@Q}
'1 2 3'
$ printf '%q\n' "$var"
1\ 2\ 3
$
Any particular reason to implement them differently?
-clark
$ var=123
$ echo ${***@Q}
'123'
$ printf '%q\n' $var
123
$
$ var='1 2 3'
$ echo ${***@Q}
'1 2 3'
$ printf '%q\n' "$var"
1\ 2\ 3
$
Any particular reason to implement them differently?
-clark