Skip to content

Fix up documentation across runtime assertions #133

Fix up documentation across runtime assertions

Fix up documentation across runtime assertions #133

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: "Build Documentation"
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
docs:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v1
# Change python version to 3.9
- uses: actions/setup-python@v4
with:
python-version: '3.9'
# Build the documentation
- name: Build and Commit Documentation
run: |
python --version
python -m pip install -r requirements_dev.txt && python -m pip install -e .
cd docsrc/
python -m sphinx.cmd.build -M html . _build/
ls _build/html/developers/
cd ../
#- uses: ammaraskar/sphinx-action@master
# with:
# pre-build-command: "python -m pip install -r requirements_dev.txt && python -m pip install -e ."
# repo-token: "${{ secrets.GITHUB_TOKEN }}"
# docs-folder: "docsrc/"
git clone https://github.com/pedal-edu/pedal.git --branch gh-pages --single-branch gh-pages
cp -r docsrc/_build/html/* gh-pages/
cd gh-pages
echo "" > .nojekyll
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add .
git commit -m "Update documentation" -a || true
# The above command will fail if no changes were present, so we ignore
# that.
- name: Push changes
uses: ad-m/github-push-action@master
with:
branch: gh-pages
directory: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
# ===============================