Overhaul cargo/rustc version management

This commit is contained in:
Michael Vines
2019-03-14 19:41:05 -07:00
parent 47ddbbe53b
commit 8f25548781
17 changed files with 96 additions and 84 deletions

View File

@ -4,10 +4,17 @@
# other workspace crates or native program crates.
set -e
export rust_version=
if [[ $1 =~ \+ ]]; then
export rust_version=$1
shift
fi
if [[ -z $1 ]]; then
echo Install directory not specified
exit 1
fi
installDir="$(mkdir -p "$1"; cd "$1"; pwd)"
cargoFeatures="$2"
echo "Install location: $installDir"
@ -35,7 +42,7 @@ BIN_CRATES=(
for crate in "${BIN_CRATES[@]}"; do
(
set -x
cargo install --force --path "$crate" --root "$installDir" --features="$cargoFeatures"
cargo "$rust_version" install --force --path "$crate" --root "$installDir" --features="$cargoFeatures"
)
done

View File

@ -28,8 +28,9 @@ if [[ -d target/cov ]]; then
fi
rm -rf target/cov/$reportName
_ cargo +nightly build --target-dir target/cov --all
_ cargo +nightly test --target-dir target/cov --lib --all -- --test-threads=1
source ci/rust-version.sh nightly
_ cargo +$rust_nightly build --target-dir target/cov --all
_ cargo +$rust_nightly test --target-dir target/cov --lib --all -- --test-threads=1
_ scripts/fetch-grcov.sh
echo "--- grcov"