当我打电话
curl --output quarto.deb -L $(curl https://quarto.org/docs/download/_prerelease.json | grep -oP "(?<=\"download_url\":\s\")https.*${ARCH}\.deb")
输出是
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 26098 100 26098 0 0 33576 0 --:--:-- --:--:-- --:--:-- 33588
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 84.5M 100 84.5M 0 0 9.9M 0 0:00:08 0:00:08 --:--:-- 11.0M
Warning: Binary output can mess up your terminal. Use "--output -" to tell
Warning: curl to output it to your terminal anyway, or consider "--output
Warning: <FILE>" to save to a file.
为什么 curl 忽略了--output
参数?-O
如果我使用(大写 O),我会得到相同的结果。
我记得几个月前使用了相同的命令并且没有遇到这个问题。
这将返回两个 url 并导致问题