From 7d335441ad87b17e7ff1bea3ea04b16d47e5567e Mon Sep 17 00:00:00 2001 From: Rain Date: Wed, 11 Oct 2023 15:29:43 -0700 Subject: [PATCH] [renovate] download install-from-binstall-release.sh into a temp dir (#4260) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Whoops, this would leave an untracked file in the repo if run (and then accidentally be checked in 😬) --- tools/renovate-post-upgrade.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/renovate-post-upgrade.sh b/tools/renovate-post-upgrade.sh index 2699f9f6a0..4a9e3aa2f2 100755 --- a/tools/renovate-post-upgrade.sh +++ b/tools/renovate-post-upgrade.sh @@ -35,8 +35,10 @@ if ! command -v cargo-hakari &> /dev/null; then if ! command -v cargo-binstall &> /dev/null; then # Fetch cargo binstall. echo "Installing cargo-binstall..." - curl --retry 3 -L --proto '=https' --tlsv1.2 -sSfO https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh - retry_command bash install-from-binstall-release.sh + tempdir=$(mktemp -d) + curl --retry 3 -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh -o "$tempdir"/install-from-binstall-release.sh + retry_command bash "$tempdir"/install-from-binstall-release.sh + rm -rf "$tempdir" fi # Install cargo-hakari.