File tree Expand file tree Collapse file tree 3 files changed +2282
-281
lines changed
Expand file tree Collapse file tree 3 files changed +2282
-281
lines changed Original file line number Diff line number Diff line change 1+ name : Publish
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*.*.*'
7+
8+ jobs :
9+ publish :
10+ runs-on : ubuntu-latest
11+
12+ strategy :
13+ matrix :
14+ node-version : [16.x]
15+
16+ steps :
17+ - uses : actions/checkout@v2
18+
19+ - name : Use Node.js ${{ matrix.node-version }}
20+ uses : actions/setup-node@v2
21+ with :
22+ node-verison : ${{ matrix.node-version }}
23+ registry-url : ' https://registry.npmjs.org'
24+
25+ - name : Cache Node.js modules
26+ uses : actions/cache@v2
27+ with :
28+ # npm cache files are stored in `~/.npm` on Linux/macOS
29+ path : ~/.npm
30+ key : ${{ runner.OS }}-node-${{ hashFiles('**/package-lock.json') }}
31+ restore-keys : |
32+ ${{ runner.OS }}-node-
33+ ${{ runner.OS }}-
34+
35+ - name : Install dependencies
36+ run : npm ci
37+
38+ - run : npm publish
39+ env :
40+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
41+
42+ - name : Release
43+ uses : softprops/action-gh-release@v1
44+ env :
45+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments