一)更改origin仓库
| git clone old-repo.git | |
| cd old-repo | |
| git remote rm origin | |
| git remote add origin new-repo.git(url) | |
| git config branch.master.remote origin | |
| git config branch.master.merge refs/heads/master | |
| git push origin master //if should pull first and fail to merge, run > git pull origin master --allow-unrelated-histories |
二)
原文:http://taoismli.blog.51cto.com/7443655/1936962