Skip to content

Commit 91680c8

Browse files
committed
chore: use envs
1 parent 869d8ba commit 91680c8

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/release-please.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ jobs:
5252
if: steps.release.outputs.releases_created == 'true'
5353
run: |
5454
# Get the first package version from release outputs
55-
VERSION=$(echo '${{ toJSON(steps.release.outputs) }}' | jq -r '.[] | select(type == "string" and test("^[0-9]")) | select(. != null)' | head -n1)
55+
VERSION=$(echo '$RELEASE_OUTPUTS' | jq -r '.[] | select(type == "string" and test("^[0-9]")) | select(. != null)' | head -n1)
5656
5757
# If version contains prerelease identifier (rc, alpha, beta, etc.), use 'next' tag
5858
if [[ "$VERSION" =~ -rc\.|-.+\. ]] || [[ "$VERSION" =~ -rc$|-(alpha|beta|next|canary) ]]; then
@@ -62,6 +62,8 @@ jobs:
6262
echo "tag=latest" >> $GITHUB_OUTPUT
6363
echo "Publishing as stable release with tag: latest"
6464
fi
65+
env:
66+
RELEASE_OUTPUTS: ${{ toJSON(steps.release.outputs) }}
6567

6668
# 8️⃣ Setup npm auth
6769
- name: Setup npm auth
@@ -73,4 +75,6 @@ jobs:
7375
# 9️⃣ Publish changed packages
7476
- name: Publish changed packages
7577
if: steps.release.outputs.releases_created == 'true'
76-
run: pnpm publish -r --filter="./packages/**" --tag ${{ steps.npm_tag.outputs.tag }} --no-git-checks
78+
run: pnpm publish -r --filter="./packages/**" --tag $TAG --no-git-checks
79+
env:
80+
TAG: ${{ steps.npm_tag.outputs.tag }}

0 commit comments

Comments
 (0)