📅  最后修改于: 2022-03-11 14:50:49.861000             🧑  作者: Mango
//download new composer version
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
//check hash
php -r "if (hash_file('sha384', 'composer-setup.php') === '906a84df04cea2aa72f40b5f787e49f22d4c2f19492ac310e8cba5b96ac8b64115ac402c8cd292b8a03482574915d1a8') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
//install composer without ssl verify
//check install dir for with this command "which composer"
php composer-setup.php --install-dir /usr/local/bin --filename composer --disable-tls