File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : NPM Publish
2
+
3
+ on :
4
+ release :
5
+ types : [published]
6
+ jobs :
7
+ build :
8
+ runs-on : ubuntu-latest
9
+ steps :
10
+ - uses : actions/checkout@v2
11
+ with :
12
+ ref : ${{ github.event.release.target_commitish }}
13
+ - name : Use Node.js 12
14
+ uses : actions/setup-node@v1
15
+ with :
16
+ node-version : 12
17
+ registry-url : https://registry.npmjs.org/
18
+ - run : npm ci
19
+ - run : git config --global user.name "Michael Heap"
20
+ - run : git config --global user.email "m@michaelheap.com"
21
+ - run : npm version ${{ github.event.release.tag_name }}
22
+ - run : npm run build --if-present
23
+ - run : npm test --if-present
24
+ - run : npm publish
25
+ env :
26
+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
27
+ - run : git push
28
+ env :
29
+ github-token : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments