9

可能重复:
如何使用 Git 更改远程存储库 URI?

我有 2 个远程仓库

remotes/origin/develop
remotes/origin/master

原来这些都是在ip-address-1。IP 地址已更改为new-ip-address-2.

如何更改我的本地引用,以便我可以在新的 IP 地址访问相同的存储库?

4

1 回答 1

0

You can try to make changes in your hosts file and force DNS resolution (old DNS to new ip, I'm using 192.168.0.2 as example)

192.168.0.2 old.dns.entry

This is not the best solution but works in some environments.

于 2012-12-17T00:27:47.140 回答