我可以在mercurial/kiln中为存储库URL分配"别名"吗?

Pet*_*ete 17 mercurial tortoisehg

我将所有个人项目保存在我的Kiln帐户中,并且我还有一个bitbucket帐户,当我需要与人们共享时,我会推送存储库.有没有办法为我设置一个repo URL的别名,所以我可以做类似的事情

hg push kiln
Run Code Online (Sandbox Code Playgroud)

要么

hg push bitbucket
Run Code Online (Sandbox Code Playgroud)

而不是每次都输入整个网址: hg push https://path/to/repo

Mar*_*vin 24

是的,您可以使用路径部分在repo的hgrc文件中执行此操作.

[paths]
default = https://path/to/repo
kiln = https://path/to/kiln
bitbucket = https://path/to/bitbucket
Run Code Online (Sandbox Code Playgroud)

如果经常创建新的repos,也可以将其添加到〜/ .hgrc文件中.