File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : release
2+ on :
3+ push :
4+ branches :
5+ - main
6+ tags :
7+ - ' *.*.*'
8+ pull_request :
9+ types :
10+ - labeled
11+
12+ jobs :
13+ release :
14+ if : github.event.action != 'labeled'
15+ runs-on : ubuntu-latest
16+ steps :
17+ - uses : actions/checkout@v2
18+ - name : Post bumpr status comment
19+ uses : haya14busa/action-bumpr@v1
20+
21+ # Get tag name.
22+ - id : tag
23+ uses : haya14busa/action-cond@v1
24+ with :
25+ cond : " ${{ startsWith(github.ref, 'refs/tags/') }}"
26+ if_true : ${{ github.ref }}
27+ if_false : ${{ steps.bumpr.outputs.next_version }}
28+
29+ - name : Release
30+ uses : justincy/github-action-npm-release@2.0.2
31+ id : release
32+ - uses : actions/setup-node@v3
33+ if : steps.release.outputs.released == 'true'
34+ with :
35+ registry-url : ' https://registry.npmjs.org'
36+ node-version : 16
37+ - name : Publish
38+ if : steps.release.outputs.released == 'true'
39+ run : echo "//registry.npmjs.org/:_authToken=${{secrets.npm_token}}" > .npmrc && npm ci && npm publish
40+ env :
41+ NODE_AUTH_TOKEN : ${{ secrets.npm_token }}
42+
43+ release-check :
44+ if : github.event.action == 'labeled'
45+ runs-on : ubuntu-latest
46+ steps :
47+ - uses : actions/checkout@v2
48+ - name : Post bumpr status comment
49+ uses : haya14busa/action-bumpr@v1
You can’t perform that action at this time.
0 commit comments