From f0cb7b36a11b998edde2a6e38dd4347d0bd72d37 Mon Sep 17 00:00:00 2001 From: Jonas Hungershausen Date: Wed, 26 Jun 2024 12:54:24 +0200 Subject: [PATCH] chore(ci): support pre-releases (#191) --- .github/workflows/release.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7b2769fb6..84b4aebaf 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -24,5 +24,12 @@ jobs: git config --global user.email "60093411+ory-bot@users.noreply.github.com" git config --global user.name "ory-bot" git add -A + - uses: actions/github-script@v7 + id: compute-dist-tag + with: + script: | + const isPrerelease = context.payload.release.prerelease; + return isPrerelease ? 'next' : 'latest'; + result-encoding: string - run: | - npx lerna publish -y ${{ github.event.release.tag_name }} --message 'chore(release): bump version to %s' --no-git-tag-version + npx lerna publish -y ${{ github.event.release.tag_name }} --dist-tag="${{ steps.compute-dist-tag.outputs.result }}" --message 'chore(release): bump version to %s' --no-git-tag-version