2024-08-12 14:35:55 +00:00
|
|
|
name: gh-pages
|
2024-08-13 07:10:26 +00:00
|
|
|
|
2024-08-12 14:35:55 +00:00
|
|
|
on:
|
|
|
|
push:
|
2024-08-13 07:10:26 +00:00
|
|
|
branches:
|
|
|
|
- 'master'
|
|
|
|
- 'main'
|
2024-08-12 14:35:55 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
NODEJS_VERSION: '16'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
publish:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
with:
|
|
|
|
submodules: recursive
|
|
|
|
- name: Setup Node.js
|
|
|
|
uses: actions/setup-node@v2
|
|
|
|
with:
|
|
|
|
node-version: ${{ env.NODEJS_VERSION }}
|
|
|
|
cache: npm
|
|
|
|
- run: npm install
|
2024-08-13 07:10:26 +00:00
|
|
|
- name: Build
|
2024-08-12 14:35:55 +00:00
|
|
|
run: npm run build
|
2024-08-13 07:10:26 +00:00
|
|
|
- name: Build static
|
|
|
|
run: npm run docs
|
2024-08-12 14:35:55 +00:00
|
|
|
- name: Publish ReDoc on Github Pages
|
|
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
|
|
with:
|
|
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
2024-08-13 07:10:26 +00:00
|
|
|
publish_dir: ./static
|