Rust语言快速安装指南


使用rustup:

  • 安装: curl https://sh.rustup.rs -sSf | sh
  • 卸载:rustup self uninstall
  • 让我们离线查看 Rust 文档: rustup doc
  • 您可以更新到更新的 Rust 版本(如果您愿意): rustup update

VSCode 集成问题

  • 如果您看到这些错误:
    • 无法启动客户端 Rust 语言服务器。
    • Rustup 不可用。
  • 将此添加到您的配置中: json "rust-client.rustupPath": "~/.cargo/bin/rustup",

工具链运行问题
  • 如果您cargo在 OS X 上运行时看到错误:
    • "Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib" cargo
  • 更改您的 OpenSSL 版本: bash brew switch openssl 1.0.2r