Skip to content

Commit e6802e1

Browse files
Merge pull request #21 from github/tiagonbotelho/publish-ghpr
Publish package to GHPR
2 parents 9e3619e + b9c50e3 commit e6802e1

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/publish.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,24 @@ jobs:
2222
- run: npm whoami; npm --ignore-scripts publish
2323
env:
2424
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
25+
26+
publish-github:
27+
runs-on: ubuntu-latest
28+
permissions:
29+
contents: read
30+
packages: write
31+
steps:
32+
- uses: actions/checkout@v3
33+
- uses: actions/setup-node@v3
34+
with:
35+
node-version: 14
36+
registry-url: https://npm.pkg.github.com
37+
cache: npm
38+
- run: npm ci
39+
- run: npm test
40+
- run: npm version ${TAG_NAME} --git-tag-version=false
41+
env:
42+
TAG_NAME: ${{ github.event.release.tag_name }}
43+
- run: npm whoami; npm --ignore-scripts publish
44+
env:
45+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)