Skip to content

Commit d7f665a

Browse files
committed
refactor: Change publish workflow trigger from release event to push event for version tags and update tag variable references.
1 parent efb8b93 commit d7f665a

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

‎.github/workflows/publish.yml‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
name: Publish to pub.dev
22

33
on:
4-
release:
5-
types: [published]
4+
push:
5+
tags:
6+
- 'v[0-9]+.[0-9]+.[0-9]+*'
67

78
concurrency:
8-
group: publish-${{ github.event.release.tag_name }}
9+
group: publish-${{ github.ref_name }}
910
cancel-in-progress: false
1011

1112
jobs:
1213
publish:
13-
if: ${{ !github.event.release.draft }}
1414
permissions:
1515
contents: read
1616
id-token: write
@@ -39,7 +39,7 @@ jobs:
3939

4040
- name: Verify release tag matches package versions
4141
env:
42-
RELEASE_TAG: ${{ github.event.release.tag_name }}
42+
RELEASE_TAG: ${{ github.ref_name }}
4343
run: |
4444
TAG_VERSION="${RELEASE_TAG#v}"
4545
for package in \
@@ -57,7 +57,7 @@ jobs:
5757
5858
- name: Publish packages
5959
env:
60-
RELEASE_TAG: ${{ github.event.release.tag_name }}
60+
RELEASE_TAG: ${{ github.ref_name }}
6161
run: |
6262
TAG_VERSION="${RELEASE_TAG#v}"
6363

0 commit comments

Comments
 (0)