Skip to content

Commit

Permalink
Auto merge of #11504 - strager:fix-profile-doc, r=weihanglo
Browse files Browse the repository at this point in the history
fix(docs): add required "inherits" option to example profile

## What does this PR try to resolve?

I copy-pasted then modified the example [profile.<name>] section in Cargo's docs. I was met with the following error:

> error: profile quick-build-incremental is missing an inherits directive (inherits is required for all profiles except dev or release)

## How should we test and review this PR?

Copy-paste the new docs into a `Cargo.toml` file, tweak, then try to use the new profile (`cargo build --profile mynewprofile`).

## Additional information

None
  • Loading branch information
bors committed Jan 16, 2023
2 parents 8681a5a + 80bc392 commit 8eb9a0c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/doc/src/reference/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ known-hosts = ["..."] # known SSH host keys
# Same keys as for [patch] in Cargo.toml

[profile.<name>] # Modify profile settings via config.
inherits = "dev" # Inherits settings from [profile.dev].
opt-level = 0 # Optimization level.
debug = true # Include debug info.
split-debuginfo = '...' # Debug info splitting behavior.
Expand Down

0 comments on commit 8eb9a0c

Please sign in to comment.