git将所有远程分支推送到新的原点

Nar*_*rek 3 git clone push mirror

假设我从远程A克隆了一个repo,现在我希望所有Remote A分支都克隆到Remote B repo.我试过用git push --mirror但是没用.我怎么解决这个问题?

Nar*_*rek 10

设置新原点后:

git remote set-url origin git://new.url.here
Run Code Online (Sandbox Code Playgroud)

我用过:

git push origin refs/remotes/origin/*:refs/heads/*
Run Code Online (Sandbox Code Playgroud)