Skip to content

Add testing workflow #7

Add testing workflow

Add testing workflow #7

Workflow file for this run

name: "Docs check and Deployment"
on:
push:
branches: [main, github-actions-test]
pull_request:
branches: [main]
jobs:
build:
runs-on: ${{matrix.os}}
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.11]
steps:
- uses: actions/checkout@v4
- name: Build using Python ${{matrix.python-version}}
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python-version}}
- uses: actions/cache@v4
with:
path: ~/.cache/pip
key: docs-${{matrix.os}}-${{matrix.python-version}}-${{ hashFiles('pyproject.toml') }}
- name: Install dependencies [pip]
run: |
pip install --upgrade pip setuptools wheel
pip install -e .[doc,all]
- name: Install Pandoc [apt-get]
run: |
sudo apt-get -y install pandoc
- name: Generate Docs [Sphinx]
run: |
sphinx-build -b html -D version=latest -D release=latest docs docs/_build
- name: Deployment of Docs
uses: JamesIves/github-pages-deploy-action@v4
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && github.repository == 'geometric-intelligence/polpo' }}
with:
branch: main
folder: docs/_build
token: ${{ secrets.DOCUMENTATION_KEY }}
repository-name: geometric-intelligence/geometric-intelligence.github.io
target-folder: polpo
clean: true