【问题标题】:How to keep git repo on vsts in sync with mercurial repo如何使 vsts 上的 git repo 与 mercurial repo 保持同步
【发布时间】:2019-11-07 09:50:58
【问题描述】:

我最近使用 hg-fast-export 将 mercurial repo 迁移到 git 并在 git VSTS 上创建了一个单一存储库。现在我希望 mono-repo 中的存储库应该与 mercurial 存储库同步。如何做到这一点? 如果有任何可用的脚本,那就太好了。

【问题讨论】:

    标签: git azure-devops mercurial


    【解决方案1】:

    正如您所说,您已使用 hg-fast-export 工具将 mercurial 存储库转换为 git 存储库,因此您希望保持 本地 git 存储库 和远程 azure devops 存储库同步,对?如果是这样,我认为您可以使用 push 共享代码。

    git push <REMOTENAME> <BRANCHNAME> 
    

    详情可以参考这位官方document

    【讨论】:

    • 实际上我希望 azure devops repo 与 mercurial repo 同步。我们还没有完全迁移,所以开发人员仍在推动对 mercurial 的更改,这些更改应该出现在 devops repo 上。
    • 我是 Azure devops 的新手,所以我可能错了。但我认为我们可以使用任务组构建管道,该管道将通过变化无常的更改更新 git repo。假设我们在一两天内执行一次此活动。这可能吗?
    • 我认为不同版本控制之间的push应该是不可行的。Azure devops repo目前只支持git和tfvc,所以如果你想将更改推送到git repo,我认为你需要先将mercurial转换为git .
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-07-08
    • 1970-01-01
    • 2020-11-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多