How to build multiple binary files (executable programs) in one Cargo project?
Hi everyone! I just started learning Rust and use Cargo for project management. I have one program that resides in `src/main.rs`, and everything works fine. But now I need to add several different utilities to the same project: one for data processing, another for report generation, and a third for running a web server. Each of them should compile into a separate executable file.
I tried simply creating several `main.rs` files in different folders, but Cargo complains. Then I came across a mention of binaries in the documentation, but didn't understand how to configure it. My current project looks like this:
```
my_project/
├── Cargo.toml
└── src/
└── main.rs
```
I want to get something like:
```
my_project/
├── Cargo.toml
└── src/
├── main.rs (first
No answers yet.
Log in to leave an answer