Skip to content

defined dependencies #42

defined dependencies

defined dependencies #42

name: Docs
on: [push, pull_request, workflow_dispatch]
permissions:
contents: write
jobs:
docs:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install Dependencies
run: |
cat pyproject.toml | grep -A9999 '\[project.dependencies\]' | grep -B9999 '\[/project.dependencies\]' | grep -v '\[project.dependencies\]\|--\|\[.*\]' | xargs -n 1 pip install
pip install sphinx sphinx_rtd_theme
- name: Sphinx Build
run: |
sphinx-build -b html docs/source docs/build
sphinx-build docs/source -W -b linkcheck -d docs/build/doctrees docs/build/html
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/dev/python_repo' }}
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build
force_orphan: true