Skip to content

Commit

Permalink
Rollup merge of #77558 - thomcc:defaults-toml-extension, r=jyn514
Browse files Browse the repository at this point in the history
Rename bootstrap/defaults/{config.toml.PROFILE => config.PROFILE.toml}

This allows these files to have okay syntax highlighting in editors, and helps avoid nagging from editors which want to suggest that I install a plugin for `*.library` files to view the `config.toml.library` or whatever.

It's a very minor change.

r?@jyn514
  • Loading branch information
JohnTitor committed Oct 6, 2020
2 parents 2b5049b + 5388eb4 commit 54d72d7
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/bootstrap/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [Non-breaking changes since the last major version]

- `x.py check` needs opt-in to check tests (--all-targets) [#77473](https://github.com/rust-lang/rust/pull/77473)
- The default bootstrap profiles are now located at `bootstrap/defaults/config.$PROFILE.toml` (previously they were located at `bootstrap/defaults/config.toml.$PROFILE`) [#77558](https://github.com/rust-lang/rust/pull/77558)


## [Version 2] - 2020-09-25

Expand Down
2 changes: 1 addition & 1 deletion src/bootstrap/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ impl Config {
include_path.push("src");
include_path.push("bootstrap");
include_path.push("defaults");
include_path.push(format!("config.toml.{}", include));
include_path.push(format!("config.{}.toml", include));
let included_toml = get_toml(&include_path);
toml.merge(included_toml);
}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions src/bootstrap/setup.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ pub fn setup(src_path: &Path, include_name: &str) {
file.display()
);
println!(
"note: this will use the configuration in {}/src/bootstrap/defaults/config.toml.{}",
"note: this will use the configuration in {}/src/bootstrap/defaults/config.{}.toml",
src_path.display(),
include_name
);
Expand All @@ -36,7 +36,7 @@ pub fn setup(src_path: &Path, include_name: &str) {
t!(fs::write(path, settings));

let include_path =
format!("{}/src/bootstrap/defaults/config.toml.{}", src_path.display(), include_name);
format!("{}/src/bootstrap/defaults/config.{}.toml", src_path.display(), include_name);
println!("`x.py` will now use the configuration at {}", include_path);

let suggestions = match include_name {
Expand Down

0 comments on commit 54d72d7

Please sign in to comment.