Skip to content

Update build-doc.yml #5

Update build-doc.yml

Update build-doc.yml #5

Workflow file for this run

name: Build documentation for GitHub Pages
on:
push:
branches:
- main
workflow_dispatch: # Enable manual action trigger
env:
PYTHONPATH: .
jobs:
build_documentation_for_github_pages:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-python@v4
with:
python-version: '3.8'
cache: 'pip' # caching pip dependencies
- run: pip install sphinx sphinx-rtd-theme
- run: python3 -m sphinx ./doc docs
- name: publish doc
shell: bash
run: |
git config user.name "GitHub Action"
git config user.email "no@mail.tmp"
git add -f docs/
git commit -m "Doc build"
git push origin `git subtree split --prefix docs/ main`:gh-pages --force