运行“bundle install”会在Gemfile.lock中将“git://”更改为“https://”

时间:2014-09-11 18:42:04

标签: ruby git bundler

当我运行bundle install时,Gemfile.lock中以remote: git://github.com开头的网址会更改为remote: https://github.com。因为我正在与其他人一起开展项目,所以我无法进行这些更改。如何强制Bundler使用git协议?

其他人似乎遇到了相反的问题,并希望使用https代替git。我尝试使用以下命令,基于this answer,但无济于事:

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

我使用的是Bundler 1.7.0和RVM。

1 个答案:

答案 0 :(得分:2)

升级到Bundler 1.7.2似乎解决了这个问题。