mercurial - 更改 Mercurial "Default"父 URL

标签 mercurial

假设我有一个 Mercurial 存储库,并且我从默认父 URL(我从中克隆它的源)中提取内容。

现在我想更改默认的父 URL(主机名更改,或者将其复制到另一台计算机等)。有没有办法做到这一点,或者我必须从新的 URL 重新克隆?

最佳答案

您甚至可以在 .hg/hgrc 文件的 [paths] 部分添加多个条目。

[paths]
default = /repo_store/hg/project1
sandbox = /repo_store/hg/project1_experimental

然后可以在mercurial命令中指定其别名。不需要指定默认存储库,但其他存储库必须类似于,

hg in            # check incoming changes from default repo
hg in default    # check incoming changes from default repo
hg in sandbox    # check incoming changes from sandbox repo
hg pull sandbox  # pull changes from sandbox repo

关于mercurial - 更改 Mercurial "Default"父 URL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/860761/

相关文章:

go - code.google.com/p/go.crypto/pbkdf2 文件未找到?

version-control - Tortoise Hg 未检测到在 SCM 管理器 (Mercurial) 中创建的用户

mercurial - 如何查找修改函数引用的所有变更集?

mercurial - Teamcity 忽略了 Mercurial 不同分支的变化

mercurial - 如何使用 TortoiseHG 进行分支

Mercurial:将补丁应用到工作目录

mercurial - hg pull 到底有什么作用?

windows - windows上的Fabfile路径问题

mercurial - 在创建多头分支、 rebase 和多次 merge 后,如何在不创建新头的情况下推送

svn - 使用 svnsync & hg convert 将 SVN 同步到 Mercurial——未命中 svn :externals?