From c3a67e32dcc6b1d37dc0d465845f3fc81a3330ad Mon Sep 17 00:00:00 2001 From: Gus Wynn Date: Wed, 16 Sep 2020 16:04:40 -0700 Subject: [PATCH] add suggested workflow to setup nightly rustup for rustc --- src/building/suggested.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/building/suggested.md b/src/building/suggested.md index cc8d92a5..a50d8a93 100644 --- a/src/building/suggested.md +++ b/src/building/suggested.md @@ -67,6 +67,22 @@ the problem. A nice side-effect of this style is that you are left with a fairly fine-grained set of commits at the end, all of which build and pass tests. This often helps reviewing. +## Configuring `rustup` to use nightly + +Some parts of the bootstrap process uses pinned, nightly versions of tools like +rustfmt. To make things like `cargo fmt` work correctly in your repo, run + +```console +cd +rustup override set nightly +``` + +after [installing a nightly toolchain] with `rustup`. Don't forget to do this for all +directories you have [setup a worktree for]. + +[installing a nightly toolchain]: https://rust-lang.github.io/rustup/concepts/channels.html?highlight=nightl#working-with-nightly-rust +[setup a worktree for]: ./suggested.html#working-on-multiple-branches-at-the-same-time + ## Incremental builds with `--keep-stage`. Sometimes just checking