Skip to content

Commit f3aa4e1

Browse files
committed
ci: enable branch-specific npm publishing (#464)
*Description of changes:* Add ref parameter to checkout action in npm-publish workflow to use the target branch specified when creating GitHub releases. This enables publishing v1.x.x from v1.x branch and v2.x.x from main branch using the correct source code for each version line. *Issue #, if available:* #461
1 parent 381ae0c commit f3aa4e1

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

.github/workflows/npm-publish.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- uses: actions/checkout@v4
15+
with:
16+
ref: ${{ github.event.release.target_commitish }}
1517
- uses: actions/setup-node@v4
1618
with:
1719
node-version: 22

0 commit comments

Comments
 (0)