diff --git a/.github/workflows/cicd-3-deploy.yaml b/.github/workflows/cicd-3-deploy.yaml index 07df86a..cda9773 100644 --- a/.github/workflows/cicd-3-deploy.yaml +++ b/.github/workflows/cicd-3-deploy.yaml @@ -75,14 +75,14 @@ jobs: env: GH_TOKEN: ${{ github.token }} run: | - if [${{inputs.ignore_prereleases=='true'}}]; then + if [[ ${{inputs.ignore_prereleases}}=='true' ]]; then json=$(gh release list --json tagName --limit 1 --exclude-drafts --exclude-pre-releases) else json=$(gh release list --json tagName --limit 1 --exclude-drafts) fi - echo $json + release_version=$(echo $json | (jq -r '.[0].tagName')) - echo $release_version + if [[ $release_version == null ]]; then exit 1; else echo $release_version; fi echo release_version=$(echo $release_version) >> $GITHUB_OUTPUT - name: "Get release version"