Auto merge of #4654 - lzutao:rustc-dev, r=phansch

Rustup for rustc-dev

cc https://github.com/rust-lang/rust/pull/64823
Closes #4651
changelog: none
This commit is contained in:
bors 2019-10-12 06:00:52 +00:00
commit 4d0e897394
3 changed files with 9 additions and 9 deletions

View File

@ -147,7 +147,7 @@ You can use [rustup-toolchain-install-master][rtim] to do that:
```bash ```bash
cargo install rustup-toolchain-install-master cargo install rustup-toolchain-install-master
rustup-toolchain-install-master -n master --force rustup-toolchain-install-master --force -n master -c rustc-dev
rustup override set master rustup override set master
cargo test cargo test
``` ```

View File

@ -17,11 +17,9 @@ install:
- curl -sSf -o rustup-init.exe https://win.rustup.rs/ - curl -sSf -o rustup-init.exe https://win.rustup.rs/
- rustup-init.exe -y --default-host %TARGET% --default-toolchain nightly - rustup-init.exe -y --default-host %TARGET% --default-toolchain nightly
- set PATH=%PATH%;C:\Users\appveyor\.cargo\bin - set PATH=%PATH%;C:\Users\appveyor\.cargo\bin
- git ls-remote https://github.com/rust-lang/rust.git master | awk '{print $1}' >rustc-hash.txt
- set /p RUSTC_HASH=<rustc-hash.txt
- del rust-toolchain - del rust-toolchain
- cargo install rustup-toolchain-install-master --debug || echo "rustup-toolchain-install-master already installed" - cargo install --git https://github.com/kennytm/rustup-toolchain-install-master --debug || echo "rustup-toolchain-install-master already installed"
- rustup-toolchain-install-master %RUSTC_HASH% -f -n master - rustup-toolchain-install-master -f -n master -c rustc-dev
- rustup component add rustfmt --toolchain nightly & exit 0 # Format test handles missing rustfmt - rustup component add rustfmt --toolchain nightly & exit 0 # Format test handles missing rustfmt
- rustup default master - rustup default master
- set PATH=%PATH%;C:\Users\appveyor\.rustup\toolchains\master\bin - set PATH=%PATH%;C:\Users\appveyor\.rustup\toolchains\master\bin

View File

@ -1,12 +1,14 @@
#!/bin/bash #!/bin/bash
# Set up the appropriate rustc toolchain # Set up the appropriate rustc toolchain
cd "$(dirname "$0")" cd "$(dirname "$0")" || exit
if ! command -v rustup-toolchain-install-master > /dev/null; then if ! command -v rustup-toolchain-install-master > /dev/null; then
cargo install rustup-toolchain-install-master --debug cargo install \
--git https://github.com/kennytm/rustup-toolchain-install-master \
--bin rustup-toolchain-install-master \
--debug
fi fi
RUSTC_HASH=$(git ls-remote https://github.com/rust-lang/rust.git master | awk '{print $1}') rustup-toolchain-install-master -f -n master -c rustc-dev
rustup-toolchain-install-master -f -n master "$RUSTC_HASH"
rustup override set master rustup override set master