首页 > 解决方案 > 可以将 Composer 配置为使用 http 而不是 git clone git@

问题描述

我们正在使用一些带有satis的私有存储库,首先尝试使用 git clone @git 下载代码,两次尝试使用 git clone http://....

有什么方法可以配置作曲家默认与私有存储库 git clone http 一起使用?

谢谢。

奥斯卡

标签: gitcomposer-phpgit-clone

解决方案


您可以尝试进行测试:

git config --global url."https://github.com/".insteadOf git@github.com:
git config --global url."https://".insteadOf git://

这将确保使用 git clone 的任何系统(如 Composer)都将使用 HTTPS URL 而不是 SSH URL。


推荐阅读