我有一堆这些来测试我的 RESTful API
$CURL \
-v \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-X POST \
-d '{"user":{"email":"user@example.com","password":"secret"}}' \
$URL/$PATH/sessions
我有点想把它缩短成类似
CURLOPTS="-v -H 'Content-Type: application/json' -H 'Accept: application/json'"
$CURL \
$CURLOPTS \
-X POST \
-d '{"user":{"email":"user@example.com","password":"secret"}}' \
$URL/$PATH/sessions
但选项似乎没有被传递。任何线索?