Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何将事物替换为双引号:
curl -u "bk322:$passw" https://api.github.com/user/repos -d "{'name':"$title"}"
我做不到
"{'name':\"$title\"}"
因为这种方式 JSON 解析器不明白我的意思。
我有一种感觉,这是您的 JSON 解析器不喜欢的单引号。
尝试:
curl -u "bk322:$passw" https://api.github.com/user/repos -d "{\"name\":\"$title\"}"