mpg*_*pgn 1 php linux composer-php
在 Composer 的网站上,我们可以看到这个命令:
curl -sS https://getcomposer.org/installer | php
Run Code Online (Sandbox Code Playgroud)
什么是选项 -sS ?
因为我也在另一个教程中看到了这个解决方案:
curl -s https://getcomposer.org/installer | php
Run Code Online (Sandbox Code Playgroud)
这取决于你想做什么。从curl 联机帮助页我们可以看到这-s意味着“静默模式”:
-s, --沉默
静音或安静模式。不要显示进度表或错误消息。使 Curl 静音。它仍然会输出您要求的数据,甚至可能输出到终端/标准输出,除非您重定向它。
这-S意味着显示错误:
-S, --show-error
与 -s 一起使用时,它会使 curl 在失败时显示错误消息。
就个人而言,我会使用-sS.