一个加速Github拉取的工具,原理基于Gitee的镜像Repo。rusgit表示用Rust开发的Git工具。
- 下载
linux
~ wget https://github.com/xbugliu/rusgit/releases/download/0.5.4/rusgit_0.5.4_x86_64-unknown-linux-musl.tar.gz
~ tar -zxvf rusgit_0.5.4_x86_64-unknown-linux-musl.tar.gz
~ export PATH=$PATH:$PWD
- 登陆Gitee, 然后从浏览器中获取登陆态Session (Gitee的check_project_duplicate接口需要)
- 设置环境变量
linux&mac
export GITEE_SESSION="your-gitee-session-n"
powershell
$env:GITEE_SESSION="your-gitee-session-n"
your-gitee-session-n替换成第一步获取到的gitee-session-n的值
- Clone
rusgit clone https://github.com/ClickHouse/ClickHouse.git
- Submodule
cd ClickHouse
rusgit submodule init
rusgit submodule update #或git submodule update