Skip to content

Commit

Permalink
Merge PR #327: Update stdout of cargo new
Browse files Browse the repository at this point in the history
  • Loading branch information
traviscross committed Oct 19, 2024
2 parents 95d5215 + d39163c commit ddb36f5
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions src/editions/creating-a-new-project.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ default:

```console
$ cargo new foo
Created binary (application) `foo` project
Creating binary (application) `foo` package
note: see more `Cargo.toml` keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
$ cat foo/Cargo.toml
[package]
name = "foo"
Expand All @@ -24,7 +25,8 @@ Rust 2018 edition could be done like this:

```console
$ cargo new --edition 2018 foo
Created binary (application) `foo` project
Creating binary (application) `foo` package
note: see more `Cargo.toml` keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
$ cat foo/Cargo.toml
[package]
name = "foo"
Expand All @@ -39,12 +41,12 @@ Don't worry about accidentally using an invalid year for the edition; the

```console
$ cargo new --edition 2019 foo
error: "2019" isn't a valid value for '--edition <YEAR>'
[possible values: 2015, 2018, 2021]
error: invalid value '2019' for '--edition <YEAR>'
[possible values: 2015, 2018, 2021, 2024]

Did you mean "2018"?
tip: a similar value exists: '2021'

For more information try --help
For more information, try '--help'.
```

You can change the value of the `edition` key by simply editing the
Expand Down

0 comments on commit ddb36f5

Please sign in to comment.