如何正确使用Gitolite实现git子模块? [英] How do I properly implement git submodules using Gitolite?

查看:96
本文介绍了如何正确使用Gitolite实现git子模块?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用Gitolite在托管版本库中创建子模块。在Gitolite之外的子系统中,子模块非常容易。然而,Gitolite似乎让事情变得复杂。

这与并排存储第二个存储库没什么两样。一旦创建了第一个存储库,就像第一个存储库创建第二个存储库一样,在第一个存储库中创建第二个存储库时,使用与第二个存储库相同的URL添加子模块。

  git submodule添加<相同的网址,如果您只是克隆> <某些路径> 
git submodule update --init --recursive

希望这有助于您。


I would like to create submodules within my hosted repository using Gitolite. Submodules are easy enough in git outside of Gitolite. However, Gitolite seems to complicate things.

解决方案

It's no different than having a second repository side by side. Once you create the second repository like you did for the first, add a submodule to the first one using the same url that you have for the second one when you created it.

git submodule add <same url as if you were just cloning> <some path>
git submodule update --init --recursive

Hope this helps.

这篇关于如何正确使用Gitolite实现git子模块?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆