Hi Clark,
>> > v=" a b c ( a'b | "
>> > a=( $v )
>> > echo "${a[@]}"
>
> There's a @ char here.
I see. It's my mistake.
But I want to pass the 6 short arguments instead of 1 long argument to
echo. (echo is just an example, it can be any command that accepts
multiple arguments.)
~$ cat ./main1.sh
#!/usr/bin/env bash
#set -o noglob
verbatim_string=" a b c ( a'b | "
args=( $verbatim_string )
#set +o noglob
echo "${args[@]}"
~$ ./main1.sh
a b c ( a'b |
--
Regards,
Peng
