File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,11 @@ name: Publish
33on :
44 release :
55 types : [created]
6- workflow_dispatch :
6+ workflow_dispatch :
7+ inputs :
8+ version :
9+ description : ' Version to publish'
10+ required : true
711
812jobs :
913
2024 - run : npm test
2125 - run : npm version ${TAG_NAME} --git-tag-version=false
2226 env :
23- TAG_NAME : ${{ github.event.release.tag_name }}
27+ TAG_NAME : ${{ github.event.inputs.version || github.event. release.tag_name }}
2428 - run : npm whoami; npm --ignore-scripts publish
2529 env :
2630 NODE_AUTH_TOKEN : ${{secrets.npm_token}}
@@ -32,13 +36,17 @@ jobs:
3236 - uses : actions/setup-node@v2
3337 with :
3438 node-version : 14
35- registry-url : https://npm.pkg.github.com /
39+ registry-url : https://registry.npmjs.org /
3640 - run : npm ci
3741 - run : npm run build --if-present
3842 - run : npm test
3943 - run : npm version ${TAG_NAME} --git-tag-version=false
4044 env :
41- TAG_NAME : ${{ github.event.release.tag_name }}
45+ TAG_NAME : ${{ github.event.inputs.version || github.event.release.tag_name }}
46+ - uses : actions/setup-node@v2
47+ with :
48+ node-version : 14
49+ registry-url : https://npm.pkg.github.com/
4250 - run : npm whoami; npm --ignore-scripts publish
4351 env :
4452 NODE_AUTH_TOKEN : ${{secrets.GITHUB_TOKEN}}
You can’t perform that action at this time.
0 commit comments