-
Notifications
You must be signed in to change notification settings - Fork 10
33 lines (27 loc) · 742 Bytes
/
ci.yml
File metadata and controls
33 lines (27 loc) · 742 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: CI
on:
- push
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: npm install
- name: Run tests
run: npm test
- name: Run build
run: npm run build
- uses: JS-DevTools/npm-publish@v1
if: github.ref == 'refs/heads/master'
with:
token: ${{ secrets.NPM_TOKEN }}
- name: Build documentation
if: github.ref == 'refs/heads/master'
run: npm run docs
- name: Publish documentation
uses: peaceiris/actions-gh-pages@v3
if: github.ref == 'refs/heads/master'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs