Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我们想将我们当前的 GIT 存储库(大约 9-10 个)与每个大约 20-50 个分支移动到 gerrit。我们真的必须手动将每个分支(最坏情况:500 个分支!)推送到 gerrit 中还是有更好的解决方案?gerrit 守护进程将在当前的 git 服务器上运行。
有几个选项:
只需使用文件系统命令将存储库移动到服务器上的正确位置。Gerrit 守护进程将毫无问题地拾取它们。
使用 git 绕过审查将它们推送到服务器。 git push $SERVER$ refs/heads/*:refs/heads/*应该可以正常工作。您需要为每个存储库执行一次此操作,它将推送该存储库中的所有分支。您需要 Gerrit 的权限才能创建分支并绕过审查。
git push $SERVER$ refs/heads/*:refs/heads/*
git 中的分支非常轻。这不应该是一个问题。