Git reset a remote repo url

For instance, the repo is:

$ git remote -v
origin  http://aaa/XXX (fetch)
origin  http://aaa/XXX (push)
$ git rev-list --count master
46

But for some reason, the repo is moved to somewhere else.

git remote set-url origin http://bbb/XXX

Then try again:

$ git remote -v
origin  http://bbb/XXX(fetch)
origin  http://bbb/XXX(push)
$ git rev-list --count master
46

你可能感兴趣的:(Git reset a remote repo url)