文章目录
修改$HOME/.cargo/config
内容
1.socks5代理
[source.crates-io]
registry = "https://github.com/rust-lang/crates.io-index"
[http]
proxy = "socks5://IP:PORT"
[https]
proxy = "socks5://IP:PORT"
2.国内镜像
[source.crates-io]
registry = "https://github.com/rust-lang/crates.io-index"
replace-with = "rsproxy"
# 中国科学技术大学
[source.ustc]
registry = "git://mirrors.ustc.edu.cn/crates.io-index"
# ByteDance
[source.rsproxy]
registry = "https://rsproxy.cn/crates.io-index"