森 • 时光机

Cargo 镜像服务器配置

配置路径 ~/.cargo/config

[source.crates-io]
registry = "https://github.com/rust-lang/crates.io-index"
replace-with = 'ustc'
[source.ustc]
registry = "git://mirrors.ustc.edu.cn/crates.io-index"
# 如果所处的环境中不允许使用 git 协议,可以把上面的地址改为
# registry = "https://mirrors.ustc.edu.cn/crates.io-index"
[http]
# 解决 SSL connect error
check-revoke = false
[source.crates-io]
replace-with = 'ustc'

[source.ustc]
# registry = "git://mirrors.ustc.edu.cn/crates.io-index"
registry = "https://mirrors.ustc.edu.cn/crates.io-index"

[http]
check-revoke = false

https://zhuanlan.zhihu.com/p/74875840
https://www.cnblogs.com/gelare/p/12912483.html

当前页面是本站的「Google AMP」版。查看和发表评论请点击:完整版 »