chore: add npm publish

This commit is contained in:
Sivan 2020-02-21 16:34:22 +08:00
parent 649c2d270c
commit a804752417

View file

@ -13,8 +13,20 @@ jobs:
uses: actions/checkout@v2
with:
persist-credentials: false
- name: Build and Deploy
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: 10
- name: NPM Install and Test
run: |
npm install
npm run test
npm run build
- name: Publish
uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
- name: Deploy to gh-pages
uses: JamesIves/github-pages-deploy-action@releases/v3
with:
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}