Skip to content

Commit f862022

Browse files
committed
doc (book)[06/14]: "Cargo Guide"/"Creating a New...": link terms to glossary
The following terms are linked to their Glossary entries: - crate - manifest - package Also note that the generated "hello world" program is known as a "binary crate".
1 parent c4c03c4 commit f862022

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

src/doc/src/guide/creating-a-new-project.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## Creating a New Package
22

3-
To start a new package with Cargo, use `cargo new`:
3+
To start a new [package][def-package] with Cargo, use `cargo new`:
44

55
```console
66
$ cargo new hello_world --bin
@@ -36,9 +36,9 @@ edition = "2018"
3636

3737
```
3838

39-
This is called a **manifest**, and it contains all of the metadata that Cargo
40-
needs to compile your package. This file is written in the [TOML] format
41-
(pronounced /tɑməl/).
39+
This is called a [***manifest***][def-manifest], and it contains all of the
40+
metadata that Cargo needs to compile your package. This file is written in the
41+
[TOML] format (pronounced /tɑməl/).
4242

4343
Here’s what’s in `src/main.rs`:
4444

@@ -48,7 +48,8 @@ fn main() {
4848
}
4949
```
5050

51-
Cargo generated a “hello world” for us. Let’s compile it:
51+
Cargo generated a “hello world” program for us, otherwise known as a
52+
[*binary crate*][def-crate]. Let’s compile it:
5253

5354
```console
5455
$ cargo build
@@ -92,3 +93,6 @@ shorter since the compiler doesn't do optimizations, but the code will run
9293
slower. Release mode takes longer to compile, but the code will run faster.
9394

9495
[TOML]: https://toml.io/
96+
[def-crate]: ../appendix/glossary.md#crate '"crate" (glossary entry)'
97+
[def-manifest]: ../appendix/glossary.md#manifest '"manifest" (glossary entry)'
98+
[def-package]: ../appendix/glossary.md#package '"package" (glossary entry)'

0 commit comments

Comments
 (0)