-
Notifications
You must be signed in to change notification settings - Fork 59
41 lines (39 loc) · 986 Bytes
/
gh-pages.yml
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
34
35
36
37
38
39
40
41
name: GitHub Pages
on:
push:
branches:
- main
pull_request:
branches:
- main
- release/*
jobs:
docs-build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup nodejs
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Test docs build
run: |
cd website
npm ci
npm run build
- name: Prepare ssh key
uses: webfactory/[email protected]
if: ${{ github.event_name == 'push' }}
with:
ssh-private-key: ${{ secrets.GH_PAGES_KEY }}
- name: Publish to GitHub Pages
if: ${{ github.event_name == 'push' }}
env:
GIT_USER: ${{ secrets.GH_PAGES_USERNAME }}
USE_SSH: true
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
cd website
npm run deploy