File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 8080 with :
8181 files : artifacts/*.tgz
8282 generate_release_notes : true
83+ prerelease : ${{ contains(github.ref_name, '-') }}
8384 env :
8485 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
8586
@@ -107,7 +108,13 @@ jobs:
107108 NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
108109
109110 - name : Publish to npm
110- run : npm publish --access public
111+ run : |
112+ PKG_VER="$(node -p "require('./package.json').version")"
113+ if [[ "$PKG_VER" == *-* ]]; then
114+ npm publish --access public --tag next
115+ else
116+ npm publish --access public
117+ fi
111118 env :
112119 NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
113120
@@ -140,6 +147,12 @@ jobs:
140147 GITHUB_REPOSITORY_OWNER : ${{ env.NPM_SCOPE_OWNER }}
141148
142149 - name : Publish to GitHub Packages
143- run : npm publish
150+ run : |
151+ PKG_VER="$(node -p "require('./package.json').version")"
152+ if [[ "$PKG_VER" == *-* ]]; then
153+ npm publish --tag next
154+ else
155+ npm publish
156+ fi
144157 env :
145158 NODE_AUTH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments