Rename config.toml.example to config.example.toml

This commit is contained in:
Thom Chiovoloni 2023-03-11 14:10:00 -08:00
parent 8a73f50d87
commit fcb2a3665f
No known key found for this signature in database
12 changed files with 16 additions and 17 deletions

1
.gitattributes vendored
View File

@ -9,7 +9,6 @@
src/etc/installer/gfx/* binary src/etc/installer/gfx/* binary
src/vendor/** -text src/vendor/** -text
Cargo.lock linguist-generated=false Cargo.lock linguist-generated=false
config.toml.example linguist-language=TOML
# Older git versions try to fix line endings on images and fonts, this prevents it. # Older git versions try to fix line endings on images and fonts, this prevents it.
*.png binary *.png binary

View File

@ -16,7 +16,7 @@ Files: compiler/*
Cargo.lock Cargo.lock
Cargo.toml Cargo.toml
CODE_OF_CONDUCT.md CODE_OF_CONDUCT.md
config.toml.example config.example.toml
configure configure
CONTRIBUTING.md CONTRIBUTING.md
COPYRIGHT COPYRIGHT

View File

@ -99,7 +99,7 @@ See [the rustc-dev-guide for more info][sysllvm].
The Rust build system uses a file named `config.toml` in the root of the The Rust build system uses a file named `config.toml` in the root of the
source tree to determine various configuration settings for the build. source tree to determine various configuration settings for the build.
Set up the defaults intended for distros to get started. You can see a full Set up the defaults intended for distros to get started. You can see a full
list of options in `config.toml.example`. list of options in `config.example.toml`.
```sh ```sh
printf 'profile = "user" \nchangelog-seen = 2 \n' > config.toml printf 'profile = "user" \nchangelog-seen = 2 \n' > config.toml

View File

@ -185,7 +185,7 @@ Some general areas that you may be interested in modifying are:
If you make a major change, please remember to: If you make a major change, please remember to:
+ Update `VERSION` in `src/bootstrap/main.rs`. + Update `VERSION` in `src/bootstrap/main.rs`.
* Update `changelog-seen = N` in `config.toml.example`. * Update `changelog-seen = N` in `config.example.toml`.
* Add an entry in `src/bootstrap/CHANGELOG.md`. * Add an entry in `src/bootstrap/CHANGELOG.md`.
A 'major change' includes A 'major change' includes

View File

@ -44,8 +44,8 @@ fn main() {
if suggest_setup { if suggest_setup {
println!("warning: you have not made a `config.toml`"); println!("warning: you have not made a `config.toml`");
println!( println!(
"help: consider running `./x.py setup` or copying `config.toml.example` by running \ "help: consider running `./x.py setup` or copying `config.example.toml` by running \
`cp config.toml.example config.toml`" `cp config.example.toml config.toml`"
); );
} else if let Some(suggestion) = &changelog_suggestion { } else if let Some(suggestion) = &changelog_suggestion {
println!("{}", suggestion); println!("{}", suggestion);
@ -57,8 +57,8 @@ fn main() {
if suggest_setup { if suggest_setup {
println!("warning: you have not made a `config.toml`"); println!("warning: you have not made a `config.toml`");
println!( println!(
"help: consider running `./x.py setup` or copying `config.toml.example` by running \ "help: consider running `./x.py setup` or copying `config.example.toml` by running \
`cp config.toml.example config.toml`" `cp config.example.toml config.toml`"
); );
} else if let Some(suggestion) = &changelog_suggestion { } else if let Some(suggestion) = &changelog_suggestion {
println!("{}", suggestion); println!("{}", suggestion);

View File

@ -55,7 +55,7 @@ pub enum DryRun {
/// Note that this structure is not decoded directly into, but rather it is /// Note that this structure is not decoded directly into, but rather it is
/// filled out from the decoded forms of the structs below. For documentation /// filled out from the decoded forms of the structs below. For documentation
/// each field, see the corresponding fields in /// each field, see the corresponding fields in
/// `config.toml.example`. /// `config.example.toml`.
#[derive(Default)] #[derive(Default)]
#[cfg_attr(test, derive(Clone))] #[cfg_attr(test, derive(Clone))]
pub struct Config { pub struct Config {
@ -325,7 +325,7 @@ fn from_str(s: &str) -> Result<Self, Self::Err> {
impl SplitDebuginfo { impl SplitDebuginfo {
/// Returns the default `-Csplit-debuginfo` value for the current target. See the comment for /// Returns the default `-Csplit-debuginfo` value for the current target. See the comment for
/// `rust.split-debuginfo` in `config.toml.example`. /// `rust.split-debuginfo` in `config.example.toml`.
fn default_for_platform(target: &str) -> Self { fn default_for_platform(target: &str) -> Self {
if target.contains("apple") { if target.contains("apple") {
SplitDebuginfo::Unpacked SplitDebuginfo::Unpacked

View File

@ -194,7 +194,7 @@ if '--help' in sys.argv or '-h' in sys.argv:
print('') print('')
print('This configure script is a thin configuration shim over the true') print('This configure script is a thin configuration shim over the true')
print('configuration system, `config.toml`. You can explore the comments') print('configuration system, `config.toml`. You can explore the comments')
print('in `config.toml.example` next to this configure script to see') print('in `config.example.toml` next to this configure script to see')
print('more information about what each option is. Additionally you can') print('more information about what each option is. Additionally you can')
print('pass `--set` as an argument to set arbitrary key/value pairs') print('pass `--set` as an argument to set arbitrary key/value pairs')
print('in the TOML configuration if desired') print('in the TOML configuration if desired')
@ -367,7 +367,7 @@ for key in known_args:
set('build.configure-args', sys.argv[1:]) set('build.configure-args', sys.argv[1:])
# "Parse" the `config.toml.example` file into the various sections, and we'll # "Parse" the `config.example.toml` file into the various sections, and we'll
# use this as a template of a `config.toml` to write out which preserves # use this as a template of a `config.toml` to write out which preserves
# all the various comments and whatnot. # all the various comments and whatnot.
# #
@ -380,7 +380,7 @@ section_order = [None]
targets = {} targets = {}
top_level_keys = [] top_level_keys = []
for line in open(rust_dir + '/config.toml.example').read().split("\n"): for line in open(rust_dir + '/config.example.toml').read().split("\n"):
if cur_section == None: if cur_section == None:
if line.count('=') == 1: if line.count('=') == 1:
top_level_key = line.split('=')[0] top_level_key = line.split('=')[0]

View File

@ -967,7 +967,7 @@ fn run(self, builder: &Builder<'_>) -> GeneratedTarball {
"RELEASES.md", "RELEASES.md",
"configure", "configure",
"x.py", "x.py",
"config.toml.example", "config.example.toml",
"Cargo.toml", "Cargo.toml",
"Cargo.lock", "Cargo.lock",
]; ];

View File

@ -286,7 +286,7 @@ fn run(self, builder: &Builder<'_>) -> LlvmResult {
(true, true) => "RelWithDebInfo", (true, true) => "RelWithDebInfo",
}; };
// NOTE: remember to also update `config.toml.example` when changing the // NOTE: remember to also update `config.example.toml` when changing the
// defaults! // defaults!
let llvm_targets = match &builder.config.llvm_targets { let llvm_targets = match &builder.config.llvm_targets {
Some(s) => s, Some(s) => s,

View File

@ -31,7 +31,7 @@ Rust's source-based code coverage requires the Rust "profiler runtime". Without
The Rust `nightly` distribution channel includes the profiler runtime, by default. The Rust `nightly` distribution channel includes the profiler runtime, by default.
> **Important**: If you are building the Rust compiler from the source distribution, the profiler runtime is _not_ enabled in the default `config.toml.example`. Edit your `config.toml` file and ensure the `profiler` feature is set it to `true` (either under the `[build]` section, or under the settings for an individual `[target.<triple>]`): > **Important**: If you are building the Rust compiler from the source distribution, the profiler runtime is _not_ enabled in the default `config.example.toml`. Edit your `config.toml` file and ensure the `profiler` feature is set it to `true` (either under the `[build]` section, or under the settings for an individual `[target.<triple>]`):
> >
> ```toml > ```toml
> # Build the profiler runtime (required when compiling with options that depend > # Build the profiler runtime (required when compiling with options that depend

View File

@ -185,7 +185,7 @@ trigger_files = [
"src/tools/x", "src/tools/x",
"configure", "configure",
"Cargo.toml", "Cargo.toml",
"config.toml.example", "config.example.toml",
"src/stage0.json" "src/stage0.json"
] ]