我想用复杂的参数执行一个函数
我想以这种方式输入它们(如果可能的话?)
set [-options here] a111 "a222" "a333 a333" "a444"
set [-options here] b111 "b222" "b333 b333" "b444"
set [-options here] c111 "c222" "c333 c333" "c444"
myfunc "$@"
myfunc
应该看到
a111 "a222" "a333 a333" "a444" ==> as the first argument with keeping ""
b111 "b222" "b333 b333" "b444" ==> as the second argument with keeping ""
c111 "c222" "c333 c333" "c444" ==> as the third argument with keeping ""
是否可以通过 set 或其他方式做到这一点?怎么做?
顺便说一句,我不想使用\"
我也不能使用'
(like '"a333 a333"'
),因为它不评估 vars