From eed30c353ece7cc50b6775e07c380034d9bfdf00 Mon Sep 17 00:00:00 2001 From: Wojciech Mazur Date: Fri, 18 Oct 2024 00:26:59 +0200 Subject: [PATCH] Fix releasing CI - ensure to use bash and make prepareSDK helper function sh compatible as fallback --- .github/workflows/ci.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 5baa8d3dea81..02420cc52471 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -767,14 +767,15 @@ jobs: run : echo "RELEASE_TAG=${GITHUB_REF#*refs/tags/}" >> $GITHUB_ENV - name: Prepare the SDKs + shell: bash run : | - function prepareSDK() { + prepareSDK() { distroSuffix="$1" artifactId="$2" artifactName="scala3-${{ env.RELEASE_TAG }}${distroSuffix}" downloadedArchive="./artifact.zip" - if [[ -f "${downloadedArchive}" ]]; then + if [ -f "${downloadedArchive}" ]; then rm "${downloadedArchive}" fi @@ -789,7 +790,7 @@ jobs: # Repackage content of .zip to .tar.gz and prepare digest tmpDir="./archive-tmp-dir" - if [[ -d "${tmpDir}" ]]; then + if [ -d "${tmpDir}" ]; then rm -r "${tmpDir}" fi mkdir "${tmpDir}"