设置github 代理

场景:执行CI需要下载GitHub仓库源码。访问很慢,有时会被中断。因此需要配置github代理。

代理网站更新频繁,可以在搜索引擎搜索关键词`github代理网站`,寻找最新可靠的代理网站。

假设代理网站是:

https://my-gh-proxy.top

单次下载配置:

`git clone https://my-gh-proxy.top/https://github.com/https://github.com/bytedance/UI-TARS-desktop\`

全局配置:

`git config --global url."https://my-gh-proxy.top/https://github.com/".insteadOf https://github.com/\`

真正配置在` ~/.gitconfig`文件里。

```bash

cat ~/.gitconfig

```

```bash

user

name = your-name

email = your-email

core

editor = vim

url "https://my-gh-proxy.top/https://github.com/"

insteadOf = https://github.com/

```

移除全局配置:

`git config --global 00unset url."https://my-gh-proxy.top/https://github.com/".insteadOf`

相关推荐
HelloGitHub33 分钟前
从被喷“假开源”到登顶 GitHub 热榜,这个开源项目上演王者归来!
开源·github
wuk99810 小时前
基于MATLAB编制的锂离子电池伪二维模型
linux·windows·github
ai小鬼头11 小时前
AIStarter如何助力用户与创作者?Stable Diffusion一键管理教程!
后端·架构·github
天天扭码12 小时前
从图片到语音:我是如何用两大模型API打造沉浸式英语学习工具的
前端·人工智能·github
独立开阀者_FwtCoder14 小时前
【Augment】 Augment技巧之 Rewrite Prompt(重写提示) 有神奇的魔法
前端·javascript·github
极客悟道16 小时前
巧解 Docker 镜像拉取难题:无需梯子和服务器,拉取数量无限制
后端·github
独立开阀者_FwtCoder17 小时前
你用 Cursor 写公司的代码安全吗?
前端·javascript·github
T__TIII18 小时前
Dify 自定义插件
人工智能·github
小皮侠1 天前
nginx的使用
java·运维·服务器·前端·git·nginx·github
汪汪队睡大觉751 天前
OpenAI-Kotlin文档详解
github