From df50b2be4a4c0c8fa4b87fa1fea0592a479382e5 Mon Sep 17 00:00:00 2001 From: Robert Kruszewski Date: Tue, 29 Sep 2026 22:17:24 -0700 Subject: [PATCH] Don't terminate rust setup early if there are no additional components to install Signed-off-by: Robert Kruszewski --- .github/actions/setup-rust/action.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/actions/setup-rust/action.yml b/.github/actions/setup-rust/action.yml index 57d51d1ca09..8924813991d 100644 --- a/.github/actions/setup-rust/action.yml +++ b/.github/actions/setup-rust/action.yml @@ -58,8 +58,12 @@ runs: shell: bash run: | rustup toolchain install "$TOOLCHAIN" --profile minimal - [[ -n "$TARGETS" ]] && rustup target add --toolchain "$TOOLCHAIN" ${TARGETS//,/ } - [[ -n "$COMPONENTS" ]] && rustup component add --toolchain "$TOOLCHAIN" ${COMPONENTS//,/ } + if [[ -n "$TARGETS" ]]; then + rustup target add --toolchain "$TOOLCHAIN" ${TARGETS//,/ } + fi + if [[ -n "$COMPONENTS" ]]; then + rustup component add --toolchain "$TOOLCHAIN" ${COMPONENTS//,/ } + fi env: TOOLCHAIN: ${{ steps.toolchain-config.outputs.toolchain }} TARGETS: ${{ inputs.targets }}