@@ -5,6 +5,7 @@ on: # yamllint disable-line rule:truthy
55 release :
66 types :
77 - " published"
8+
89jobs :
910 publish :
1011 name : Publish to NPM
@@ -15,14 +16,15 @@ jobs:
1516 with :
1617 node-version : 18
1718 - uses : bahmutov/npm-install@v1
18- - run : yarn test
1919 # Set the version in package.json to match the tag
2020 - name : Write release version
2121 run : |
2222 VERSION=${GITHUB_REF_NAME#v}
2323 echo Version: $VERSION
2424 echo "VERSION=$VERSION" >> $GITHUB_ENV
25- - run : " npm version ${VERSION}"
25+ # NOTE: the flag is necessary because otherwise `npm version <version>` attempts to
26+ # cut a git tag with that version, which fails because the git user isn't configured.
27+ - run : " npm version ${VERSION} --no-git-tag-version"
2628 - uses : JS-DevTools/npm-publish@v3
2729 with :
2830 token : ${{ secrets.NPM_TOKEN }}
@@ -45,13 +47,15 @@ jobs:
4547 - uses : bahmutov/npm-install@v1
4648 with :
4749 working-directory : ./js-dist
50+ # Set the version in package.json to match the tag
4851 - name : Write release version
4952 run : |
5053 VERSION=${GITHUB_REF_NAME#v}
5154 echo Version: $VERSION
5255 echo "VERSION=$VERSION" >> $GITHUB_ENV
53- # Set the version in package.json to match the tag
54- - run : " npm version ${VERSION}"
56+ # NOTE: the flag is necessary because otherwise `npm version <version>` attempts to
57+ # cut a git tag with that version, which fails because the git user isn't configured.
58+ - run : " npm version ${VERSION} --no-git-tag-version"
5559 working-directory : ./js-dist
5660 - uses : JS-DevTools/npm-publish@v3
5761 with :
0 commit comments