From 1b20e106b6c0dc5dbd9033d07317fd04331069c0 Mon Sep 17 00:00:00 2001 From: "oxide-renovate[bot]" <146848827+oxide-renovate[bot]@users.noreply.github.com> Date: Wed, 11 Oct 2023 04:07:46 +0000 Subject: [PATCH] Update Rust crate indicatif to 0.17.7 --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- install-from-binstall-release.sh | 36 ++++++++++++++++++++++++++++++++ 3 files changed, 39 insertions(+), 3 deletions(-) create mode 100644 install-from-binstall-release.sh diff --git a/Cargo.lock b/Cargo.lock index 306e9530496..38a36d57a1d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3467,9 +3467,9 @@ dependencies = [ [[package]] name = "indicatif" -version = "0.17.6" +version = "0.17.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b297dc40733f23a0e52728a58fa9489a5b7638a324932de16b41adc3ef80730" +checksum = "fb28741c9db9a713d93deb3bb9515c20788cef5815265bee4980e87bde7e0f25" dependencies = [ "console", "instant", diff --git a/Cargo.toml b/Cargo.toml index da7b582fe38..731bed9c960 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -209,7 +209,7 @@ hyper-rustls = "0.24.1" hyper-staticfile = "0.9.5" illumos-utils = { path = "illumos-utils" } indexmap = "2.0.0" -indicatif = { version = "0.17.6", features = ["rayon"] } +indicatif = { version = "0.17.7", features = ["rayon"] } installinator = { path = "installinator" } installinator-artifactd = { path = "installinator-artifactd" } installinator-artifact-client = { path = "clients/installinator-artifact-client" } diff --git a/install-from-binstall-release.sh b/install-from-binstall-release.sh new file mode 100644 index 00000000000..7630eeb4a72 --- /dev/null +++ b/install-from-binstall-release.sh @@ -0,0 +1,36 @@ +#!/bin/bash + +set -euxo pipefail + +cd "$(mktemp -d)" + +base_url="https://github.com/cargo-bins/cargo-binstall/releases/latest/download/cargo-binstall-" + +os="$(uname -s)" +if [ "$os" == "Darwin" ]; then + url="${base_url}universal-apple-darwin.zip" + curl -LO --proto '=https' --tlsv1.2 -sSf "$url" + unzip cargo-binstall-universal-apple-darwin.zip +elif [ "$os" == "Linux" ]; then + machine="$(uname -m)" + target="${machine}-unknown-linux-musl" + if [ "$machine" == "armv7" ]; then + target="${target}eabihf" + fi + + url="${base_url}${target}.tgz" + curl -L --proto '=https' --tlsv1.2 -sSf "$url" | tar -xvzf - +else + echo "Unsupported OS ${os}" + exit 1 +fi + +./cargo-binstall -y --force cargo-binstall + +CARGO_HOME="${CARGO_HOME:-$HOME/.cargo}" + +if ! [[ ":$PATH:" == *":$CARGO_HOME/bin:"* ]]; then + echo + printf "\033[0;31mYour path is missing %s, you might want to add it.\033[0m\n" "$CARGO_HOME/bin" + echo +fi