仓库迁移
cnb官网提供了迁移工具,可以批量将代码从github迁移到cnb。
https://docs.cnb.cool/zh/guide/migration-tools.html
Git 配置代理
不配置加速,工具同步很慢,代码会先同步到本地,然后上传到远程仓库。
Git 可以通过以下命令单独配置 HTTP 代理,不影响系统全局设置:
# 设置 HTTP 代理
git config --global http.proxy http://proxy.example.com:8080
# 设置 HTTPS 代理
git config --global https.proxy http://proxy.example.com:8080
# 可选:仅为特定域名设置代理
git config --global http.https://github.com.proxy http://proxy.example.com:8080
如果需要取消代理配置,可以使用:
git config --global --unset http.proxy
git config --global --unset https.proxy
查看当前代理配置:
git config --global --get http.proxy
git config --global --get https.proxy