File tree Expand file tree Collapse file tree 1 file changed +39
-0
lines changed
Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Publish node.js package to npm
2+
3+ on :
4+ release :
5+ types : [created]
6+
7+ jobs :
8+ build :
9+
10+ runs-on : ubuntu-latest
11+
12+ strategy :
13+ matrix :
14+ node-version : [10.x, 12.x]
15+
16+ steps :
17+ - uses : actions/checkout@v1
18+ - name : Use Node.js ${{ matrix.node-version }}
19+ uses : actions/setup-node@v1
20+ with :
21+ node-version : ${{ matrix.node-version }}
22+ - run : npm install
23+ - run : npm run build --if-present
24+ - run : npm run lint-test
25+ - run : npm test
26+
27+ publish-npm :
28+ needs : build
29+ runs-on : ubuntu-latest
30+ steps :
31+ - uses : actions/checkout@v1
32+ - uses : actions/setup-node@v1
33+ with :
34+ node-version : 10
35+ registry-url : https://registry.npmjs.org/
36+ - run : npm ci
37+ - run : npm publish
38+ env :
39+ NODE_AUTH_TOKEN : ${{secrets.npm_token}}
You can’t perform that action at this time.
0 commit comments