Skip to content

Commit 554e0e9

Browse files
committed
Adjust actions
1 parent b136fe7 commit 554e0e9

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

.github/workflows/release.yml

+23-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
1-
name: Publish Package to npmjs
1+
name: Release and publish the package
22
on:
3-
release:
4-
types: [published]
3+
push:
4+
tags:
5+
- "v*"
6+
7+
permissions:
8+
contents: write
9+
510
jobs:
6-
build:
11+
release-npmjs:
712
runs-on: ubuntu-latest
813
steps:
914
- uses: actions/checkout@v4
@@ -17,3 +22,17 @@ jobs:
1722
- run: yarn npm publish
1823
env:
1924
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
25+
release-github:
26+
runs-on: ubuntu-latest
27+
steps:
28+
- uses: actions/checkout@v4
29+
- uses: actions/setup-node@v4
30+
with:
31+
node-version: '20.x'
32+
registry-url: 'https://npm.pkg.github.com'
33+
# Defaults to the user or organization that owns the workflow file
34+
scope: '@traut'
35+
- run: yarn
36+
- run: yarn npm publish
37+
env:
38+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)