How can I store an argument vector with an argument containing spaces in a
For example, I want
2.sh to print
#!/bin/bash ARGV='a "b c"' ./2.sh $ARGV
#!/bin/bash echo $2
You should use an array instead of a string:
When the array expansion is quoted, each element of the array is properly expanded.