From the course: First Look: Rust

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Hello, Cargo!

Hello, Cargo! - Rust Tutorial

From the course: First Look: Rust

Start my 1-month free trial

Hello, Cargo!

- [Narrator] Cargo is Rust's build system and package manager. And Rustecians use Cargo to manage their Rust projects because it makes a lot of things easier. For example, cargo take care of building your code, downloading the libraries your code depends on and building those libraries. The core libraries your code needs as dependencies. The simplest Rust programs, like the we've written so far, don't have any dependencies. So right now you'll be using the part of Cargo that can take care of building your code. As you write more complex Rust programs, you'll want to add dependencies. And if you start off using Cargo that will be a lot easier to do. Let's first check if Cargo is installed in your system. So open up your PowerShell and type cargo space --version. If you'll get a version number like this, you're good to go. If you see an error like command not found, then you should look at the documentation and install Cargo separately. Let's create a new project using cargo and look at…

Contents