mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-01 03:03:40 +00:00
rustup cargo install-upgrade
This commit is contained in:
parent
cc35165f52
commit
6173478cf8
@ -12,7 +12,7 @@ cache:
|
||||
directories:
|
||||
- $HOME/.cargo
|
||||
before_cache:
|
||||
- cargo install -Z install-upgrade cargo-cache --debug
|
||||
- cargo install cargo-cache --debug
|
||||
- find $HOME/.cargo/bin/ ! -type d -exec strip {} \;
|
||||
- cargo cache --autoclean
|
||||
|
||||
@ -28,7 +28,7 @@ install:
|
||||
- |
|
||||
if [[ -z ${INTEGRATION} ]]; then
|
||||
if ! rustup component add rustfmt; then
|
||||
cargo install -Z install-upgrade --git https://github.com/rust-lang/rustfmt --bin rustfmt
|
||||
cargo install --git https://github.com/rust-lang/rustfmt --bin rustfmt
|
||||
fi
|
||||
if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
|
||||
. $HOME/.nvm/nvm.sh
|
||||
|
@ -18,7 +18,7 @@ cache:
|
||||
- '%USERPROFILE%\.cargo'
|
||||
# before cache
|
||||
after_test:
|
||||
- cargo install -Z install-upgrade cargo-cache --debug
|
||||
- cargo install cargo-cache --debug
|
||||
- cargo cache --autoclean
|
||||
|
||||
install:
|
||||
@ -27,7 +27,7 @@ install:
|
||||
- set PATH=%USERPROFILE%\.cargo\bin;%PATH%
|
||||
- rustup component add rustfmt --toolchain nightly & exit 0 # Format test handles missing rustfmt
|
||||
- del rust-toolchain
|
||||
- cargo install -Z install-upgrade rustup-toolchain-install-master
|
||||
- cargo install rustup-toolchain-install-master
|
||||
- rustup-toolchain-install-master -f -n master -c rustc-dev
|
||||
- rustup override set master
|
||||
- rustc -V
|
||||
|
@ -5,14 +5,13 @@ set -e
|
||||
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
ERRNO=0
|
||||
RTIM_PATH=$(command -v rustup-toolchain-install-master) || ERRNO=$?
|
||||
RTIM_PATH=$(command -v rustup-toolchain-install-master)
|
||||
CARGO_HOME=${CARGO_HOME:-$HOME/.cargo}
|
||||
|
||||
# Check if people also install RTIM in other locations beside
|
||||
# ~/.cargo/bin
|
||||
if [[ "$ERRNO" -ne 0 ]] || [[ "$RTIM_PATH" == $CARGO_HOME/bin/rustup-toolchain-install-master ]]; then
|
||||
cargo install -Z install-upgrade rustup-toolchain-install-master
|
||||
if [[ "$RTIM_PATH" == $CARGO_HOME/bin/rustup-toolchain-install-master ]]; then
|
||||
cargo +nightly install rustup-toolchain-install-master
|
||||
else
|
||||
VERSION=$(rustup-toolchain-install-master -V | grep -o "[0-9.]*")
|
||||
REMOTE=$(cargo search rustup-toolchain-install-master | grep -o "[0-9.]*")
|
||||
|
Loading…
Reference in New Issue
Block a user