降低composer版本(亲测可行)
1.如果想把composer从2版本降到1版本
composer self-update 1.4.1
2、如果想降到1版本
composer self-update --1
3.测试
降低版本前:因我原来安装PHP7.3,composer version 2.3.5
降低后:php降低为5.5后,报错,大致意思是composer 2.3以后停止对低于php7.2.5的支持,需要降低composer 版本到2.2
Composer 2.3.0 dropped support for PHP <7.2.5 and you are running 5.5.38, please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.
操作过程:
注意:将PHP换回7.3后执行,否则还是报上面的错
composer self-update --2.2
效果图
如果想回退到composer version 2.3.5
composer self-update --rollback
赞赏码
非学,无以致疑;非问,无以广识