Rust Mac 安装
- 通过命令行安装:curl https://sh.rustup.rs -sSf | sh
- 安装完成通过命令: rustc –version
Rust With VSCode
- VSCode中通过扩展器搜素Rust 可以看到Rust(rls)的扩展进行安装
- 使用cargo来创建项目:cargo new hello-world
- 使用VSCode打开hello-world创建的项目
- 然后使用终端安装其他扩展:rustup component add rls rust-analysis rust-src
- 安装crates,crates相当于Node的NPM,PHP的Composer,Java 的maven;Seray Uzgur 提交的 crates 插件,安装这个插件后可以管理dependencies
- 安装Toml插件即可实现打开cargo.toml会高亮