Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我们有现有的存储库,我必须将源代码移动到新存储库并保留历史记录。
在 Github 上创建一个 repo,然后使用命令行
cd /path/to/your/repo git remote set-url origin <github URL> git pull origin master git push -u origin master
基本上,您将默认origin远程 URL 更改为指向 Github 的。
origin