Skip to content

Commit 977d5e9

Browse files
authored
Update publish.yml
1 parent 9171cee commit 977d5e9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.github/workflows/publish.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ jobs:
1111
with:
1212
node-version: latest
1313
registry-url: 'https://registry.npmjs.org'
14+
cache: npm
1415
- run: npm ci
1516
- run: npm test
17+
- name: Get latest tag and update version in package.json file
18+
run: npm version $(git tag | sort -r --version-sort | head -n1 | cut -c2-) -no-git-tag-version -f
1619
- run: npm publish
1720
env:
1821
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)