使用 githubproxy.cc 代理服务,为国内访问 GitHub 提供加速支持。
当前使用的代理服务:
将 GitHub 仓库链接前加上 https://githubproxy.cc/ 前缀:
# 原始链接
git clone https://github.com/username/repo.git
# 加速链接
git clone https://githubproxy.cc/https://github.com/username/repo.git
支持以下类型的 GitHub 资源加速:
https://raw.githubusercontent.com/...
gist.github.com 或 gist.githubusercontent.com
# 原始链接
wget https://raw.githubusercontent.com/username/repo/main/file.txt
# 加速链接
wget https://githubproxy.cc/https://raw.githubusercontent.com/username/repo/main/file.txt
使用 scripts/convert_url.py 自动转换 GitHub 链接:
python scripts/convert_url.py "https://github.com/username/repo.git"
| 原始链接格式 | 转换后格式 |
|---|---|
https://github.com/username/repo.git |
https://githubproxy.cc/https://github.com/username/repo.git |
https://raw.githubusercontent.com/... |
https://githubproxy.cc/https://raw.githubusercontent.com/... |
https://github.com/.../releases/download/... |
https://githubproxy.cc/https://github.com/.../releases/download/... |
https://github.com/.../archive/... |
https://githubproxy.cc/https://github.com/.../archive/... |