更新 README.md
This commit is contained in:
parent
33a2ae3d16
commit
f6415724be
10
README.MD
10
README.MD
@ -10,21 +10,23 @@
|
|||||||
- [Rust 程序设计语言](https://kaisery.github.io/trpl-zh-cn/)
|
- [Rust 程序设计语言](https://kaisery.github.io/trpl-zh-cn/)
|
||||||
|
|
||||||
|
|
||||||
## 子包创建
|
## 子包
|
||||||
|
### 通用
|
||||||
|
#### 新建子包
|
||||||
例子:
|
例子:
|
||||||
```shell
|
```shell
|
||||||
cargo new 5.function --name function
|
cargo new 5.function --name function
|
||||||
```
|
```
|
||||||
### 编译某个子包
|
#### 编译某个子包
|
||||||
```shell
|
```shell
|
||||||
cargo build --manifest-path 5.function/Cargo.toml
|
cargo build --manifest-path 5.function/Cargo.toml
|
||||||
```
|
```
|
||||||
### 运行某个子包
|
#### 运行某个子包
|
||||||
```shell
|
```shell
|
||||||
cargo run --manifest-path 5.function/Cargo.toml
|
cargo run --manifest-path 5.function/Cargo.toml
|
||||||
```
|
```
|
||||||
|
|
||||||
### 工作空间 workspace
|
### 基于 工作空间 workspace 管理子包
|
||||||
参考文档
|
参考文档
|
||||||
- https://course.rs/cargo/reference/workspaces.html
|
- https://course.rs/cargo/reference/workspaces.html
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user