diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-03-18 10:09:28 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-18 10:09:28 +0100 |
| commit | 42293e3c68e93c9518211a56f9bfa888508888ab (patch) | |
| tree | e3a912d5836cd36fbd96a7d1aa02923a0a042cef | |
| parent | 098db784c714d8058bb1f1343e27fc7431f8f96e (diff) | |
| parent | 1be80d48fa0f3fdea8dec7f05426dd619dfdf411 (diff) | |
| download | rust-42293e3c68e93c9518211a56f9bfa888508888ab.tar.gz rust-42293e3c68e93c9518211a56f9bfa888508888ab.zip | |
Rollup merge of #138080 - moxian:bootstrap-breadcrumb, r=jieyouxu
Leave a breadcrumb towards bootstrap config documentation in `bootstrap.toml` I was curious as to the possible bootstrap options I can put in config.toml, but had some trouble figuring it out. There is no obvious documentation in `config.toml` (obviously), the documentation in src/bootstrap/defaults is *nice*, but also rather sparse, by design. I had to dive into the parsing code, and stuble upon [a very helpful doc comment](https://github.com/rust-lang/rust/blob/30f168ef811aec63124eac677e14699baa9395bd/src/bootstrap/src/core/config/config.rs#L181) there to realize that `config.example.toml` *exists*, and that it does, indeed, answer all of my questions. So I figured it might be worth making this journey a bit easier for future contributors and add mention the `config.example.toml` directly in `config.toml`. Now, since #137081 is in-flight which would rename `config(.example)?.toml` to `bootstrap(.example)?.toml`, I figure it's better to wait until that one lands, and submit the "new", "correct" filename upfront, instead of landing `config.toml` now and updating it to `boostrap.toml` later. `@rustbot` blocked #137081
| -rw-r--r-- | src/bootstrap/src/core/build_steps/setup.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/bootstrap/src/core/build_steps/setup.rs b/src/bootstrap/src/core/build_steps/setup.rs index 636d51e0e90..80d92135dd3 100644 --- a/src/bootstrap/src/core/build_steps/setup.rs +++ b/src/bootstrap/src/core/build_steps/setup.rs @@ -214,8 +214,9 @@ fn setup_config_toml(path: &Path, profile: Profile, config: &Config) { let latest_change_id = CONFIG_CHANGE_HISTORY.last().unwrap().change_id; let settings = format!( - "# Includes one of the default files in {PROFILE_DIR}\n\ - profile = \"{profile}\"\n\ + "# See bootstrap.example.toml for documentation of available options\n\ + #\n\ + profile = \"{profile}\" # Includes one of the default files in {PROFILE_DIR}\n\ change-id = {latest_change_id}\n" ); |
