github克隆仓库与本地化
GitHub Import repository


- 需要克隆的仓库地址;
- 重命名仓库名称;
- 选择仓库属性;
- 开始导入,导入成功后会通过邮件通知。
本人Github 克隆到本地电脑
将上述克隆到自己github的仓库再克隆到本地电脑:

git clone https://github.com/**/**.git
cd **
# 查看仓库所属
git remote -v
本地仓库重定向到本人Github
如果本地电脑的仓库是从别人的Github仓库克隆的,需要重新指向自己的Github仓库。
git remote -v
# 输出
# origin https://ghfast.top/https://github.com/JokerYan/NeRF-DS.git (fetch)
# origin https://ghfast.top/https://github.com/JokerYan/NeRF-DS.git (push)
首先需要在字迹的Github上创建一个相关的仓库;
然后复制仓库地址;
执行命令替换远程源:
git remote set-url origin https://github.com/你的用户名/你的仓库名.git
示例:
git remote set-url origin https://github.com/usr/NeRF-DS.git
git remote -v
# origin https://github.com/usr/NeRF-DS.git (fetch)
# origin https://github.com/usr/NeRF-DS.git (push)
clone可以使用https://ghfast.top代理加速;
push则不适合使用代理,需要用原生地址
# fetch 用 shturl.cc/
git remote set-url origin https://shturl.cc//https://github.com/你的账号/你的仓库.git
# push 切回 github.com
git remote set-url --push origin https://github.com/你的账号/你的仓库.git

4147

被折叠的 条评论
为什么被折叠?



