Skip to content

Missing closing quotes on api_routes example (#2123) #6

Missing closing quotes on api_routes example (#2123)

Missing closing quotes on api_routes example (#2123) #6

Workflow file for this run

name: documentation
on:
pull_request:
branches: [master]
paths: ['docs/**']
push:
branches: [master]
paths: ['docs/**']
jobs:
pull-request-check:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Test Build
working-directory: ./docs
run: |
npm ci
npm run build
gh-pages-release:
if: github.event_name == 'push'
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
path: master
- uses: actions/checkout@v4
with:
ref: gh-pages
path: gh-pages
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Build docusaurus
working-directory: master/docs
id: build
run: |
echo "sha=$(git rev-parse HEAD)" >> $GITHUB_OUTPUT
npm ci
npm run build
- name: Release to github pages
env:
GIT_TOKEN: ${{ secrets.GITHUB_TOKEN }}
working-directory: gh-pages
run: |
git config --local user.name "github-actions[bot]"
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
# Remove all files except .git
git rm -r *
# Copy the build files from master/docs/build to gh-pages
cp -r ../master/docs/build/* .
# Commit and push
git add .
git commit -m "Update documentation based on ${{ steps.build.outputs.sha }}"
git push origin gh-pages