From fb07626bd2fc581b163992e116f5184ee25cc439 Mon Sep 17 00:00:00 2001 From: Jordon Leach <40806497+jordojordo@users.noreply.github.com> Date: Thu, 10 Oct 2024 08:55:59 -0400 Subject: [PATCH] [Backport 2.8] Fix reference to tsc binary when publishing shell (#12191) * Fix reference to tsc binary when publishing shell (#12176) * Fix BASE_DIR path * Add pipefail for proper error handling * Bump shell package 1.2.5-rc.2 --- shell/package.json | 2 +- shell/scripts/publish-shell.sh | 7 +++---- shell/scripts/typegen.sh | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/shell/package.json b/shell/package.json index dd953eeb17d..f2dda9fd9f1 100644 --- a/shell/package.json +++ b/shell/package.json @@ -1,6 +1,6 @@ { "name": "@rancher/shell", - "version": "1.2.5-rc.1", + "version": "1.2.5-rc.2", "description": "Rancher Dashboard Shell", "repository": "https://github.com/rancherlabs/dashboard", "license": "Apache-2.0", diff --git a/shell/scripts/publish-shell.sh b/shell/scripts/publish-shell.sh index 99e1e9409ab..99fdac978dd 100755 --- a/shell/scripts/publish-shell.sh +++ b/shell/scripts/publish-shell.sh @@ -1,10 +1,9 @@ #!/usr/bin/env bash +set -eo pipefail + SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd)" -BASE_DIR="$( - cd $SCRIPT_DIR && cd ../.. & - pwd -)" +BASE_DIR="$(cd $SCRIPT_DIR && cd ../.. && pwd)" SHELL_DIR=$BASE_DIR/shell/ CREATORS_DIR=$BASE_DIR/creators/extension FORCE_PUBLISH_TO_NPM="false" diff --git a/shell/scripts/typegen.sh b/shell/scripts/typegen.sh index fc0e2ad9d26..531491ad85e 100755 --- a/shell/scripts/typegen.sh +++ b/shell/scripts/typegen.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" -BASE_DIR="$( cd $SCRIPT_DIR && cd ../.. & pwd)" +BASE_DIR="$(cd $SCRIPT_DIR && cd ../.. && pwd)" SHELL_DIR=$BASE_DIR/shell echo "Generating typescript definitions"