rustup —— The Rust toolchain installer
这应该是大家入手Rust最熟悉的工具了,主要用于管理工具链中的其他工具,检查Rust工具链的版本并升级。
cargo
rust中的包管理工具和项目管理工具,类似JavaScript中的npm。
在rust中,你可以使用cargo init或cargo new快速新建一个Rust项目,
使用cargo build快速编译,
使用cargo install [package name] 快速安装依赖
…
rustc
这个工具可以把我们编写的Rust源码编译成可执行文件,类似c语言中的gcc。
rustfmt
Rust的代码格式化工具,支持代码格式检查和一键格式化。
rustdoc
The standard Rust distribution ships with a tool called rustdoc. Its job is to generate documentation for Rust projects. On a fundamental level, Rustdoc takes as an argument either a crate root or a Markdown file, and produces HTML, CSS, and JavaScript. ——from 官方文档
简单说,这个工具可以帮你快速生成项目文档。
rust-gdb & rust-gdbgui
类似gdb的debug工具和它的gui版本。
clippy
Checks a file to catch common mistakes and improve your Rust code.
Run clippy-driver with the same arguments you use for rustc。
这个工具可以帮助检查你的Rust代码,帮你找出常见错误和改进方案。