diff --git a/.gitattributes b/.gitattributes index 51a670b5fbe..d29c15fe712 100644 --- a/.gitattributes +++ b/.gitattributes @@ -9,7 +9,6 @@ src/etc/installer/gfx/* binary src/vendor/** -text 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. *.png binary diff --git a/.reuse/dep5 b/.reuse/dep5 index dc6a60e6239..9a59f455fe9 100644 --- a/.reuse/dep5 +++ b/.reuse/dep5 @@ -16,7 +16,7 @@ Files: compiler/* Cargo.lock Cargo.toml CODE_OF_CONDUCT.md - config.toml.example + config.example.toml configure CONTRIBUTING.md COPYRIGHT diff --git a/README.md b/README.md index c424bd12ffd..c19e129a920 100644 --- a/README.md +++ b/README.md @@ -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 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 - list of options in `config.toml.example`. + list of options in `config.example.toml`. ```sh printf 'profile = "user" \nchangelog-seen = 2 \n' > config.toml diff --git a/config.toml.example b/config.example.toml similarity index 100% rename from config.toml.example rename to config.example.toml diff --git a/src/bootstrap/README.md b/src/bootstrap/README.md index 71eee8968e2..253d504d7bd 100644 --- a/src/bootstrap/README.md +++ b/src/bootstrap/README.md @@ -185,7 +185,7 @@ Some general areas that you may be interested in modifying are: If you make a major change, please remember to: + 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`. A 'major change' includes diff --git a/src/bootstrap/bin/main.rs b/src/bootstrap/bin/main.rs index 3856bb64fb3..b345bf9fb83 100644 --- a/src/bootstrap/bin/main.rs +++ b/src/bootstrap/bin/main.rs @@ -44,8 +44,8 @@ fn main() { if suggest_setup { println!("warning: you have not made a `config.toml`"); println!( - "help: consider running `./x.py setup` or copying `config.toml.example` by running \ - `cp config.toml.example config.toml`" + "help: consider running `./x.py setup` or copying `config.example.toml` by running \ + `cp config.example.toml config.toml`" ); } else if let Some(suggestion) = &changelog_suggestion { println!("{}", suggestion); @@ -57,8 +57,8 @@ fn main() { if suggest_setup { println!("warning: you have not made a `config.toml`"); println!( - "help: consider running `./x.py setup` or copying `config.toml.example` by running \ - `cp config.toml.example config.toml`" + "help: consider running `./x.py setup` or copying `config.example.toml` by running \ + `cp config.example.toml config.toml`" ); } else if let Some(suggestion) = &changelog_suggestion { println!("{}", suggestion); diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs index 4f417d36511..fc5aa8a245d 100644 --- a/src/bootstrap/config.rs +++ b/src/bootstrap/config.rs @@ -55,7 +55,7 @@ pub enum DryRun { /// 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 /// each field, see the corresponding fields in -/// `config.toml.example`. +/// `config.example.toml`. #[derive(Default)] #[cfg_attr(test, derive(Clone))] pub struct Config { @@ -325,7 +325,7 @@ fn from_str(s: &str) -> Result { impl SplitDebuginfo { /// 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 { if target.contains("apple") { SplitDebuginfo::Unpacked diff --git a/src/bootstrap/configure.py b/src/bootstrap/configure.py index 5278f0c10b3..b326ae402aa 100755 --- a/src/bootstrap/configure.py +++ b/src/bootstrap/configure.py @@ -194,7 +194,7 @@ if '--help' in sys.argv or '-h' in sys.argv: print('') print('This configure script is a thin configuration shim over the true') 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('pass `--set` as an argument to set arbitrary key/value pairs') print('in the TOML configuration if desired') @@ -367,7 +367,7 @@ for key in known_args: 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 # all the various comments and whatnot. # @@ -380,7 +380,7 @@ section_order = [None] targets = {} 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 line.count('=') == 1: top_level_key = line.split('=')[0] diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs index c9384004100..a3d9cb3e10c 100644 --- a/src/bootstrap/dist.rs +++ b/src/bootstrap/dist.rs @@ -967,7 +967,7 @@ fn run(self, builder: &Builder<'_>) -> GeneratedTarball { "RELEASES.md", "configure", "x.py", - "config.toml.example", + "config.example.toml", "Cargo.toml", "Cargo.lock", ]; diff --git a/src/bootstrap/native.rs b/src/bootstrap/native.rs index 7f6d80c91ad..040e36ea5f8 100644 --- a/src/bootstrap/native.rs +++ b/src/bootstrap/native.rs @@ -286,7 +286,7 @@ fn run(self, builder: &Builder<'_>) -> LlvmResult { (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! let llvm_targets = match &builder.config.llvm_targets { Some(s) => s, diff --git a/src/doc/rustc/src/instrument-coverage.md b/src/doc/rustc/src/instrument-coverage.md index da91e25595c..b0b2f419642 100644 --- a/src/doc/rustc/src/instrument-coverage.md +++ b/src/doc/rustc/src/instrument-coverage.md @@ -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. -> **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.]`): +> **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.]`): > > ```toml > # Build the profiler runtime (required when compiling with options that depend diff --git a/triagebot.toml b/triagebot.toml index 0388ce9fc98..a81f66fe168 100644 --- a/triagebot.toml +++ b/triagebot.toml @@ -185,7 +185,7 @@ trigger_files = [ "src/tools/x", "configure", "Cargo.toml", - "config.toml.example", + "config.example.toml", "src/stage0.json" ]