docs with enw notebooks #244
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Deploy documentation when a new VERSION is release to the main branch | |
# N.B. currently doesn't build the dev_resources/docs: need to do that locally with | |
# ./scrips/make_dev_resources/docs.sh | |
# Author: Matt Clifford <[email protected]> | |
# License: BSD 3-Clause License | |
name: Publish Documentation to Github Pages | |
on: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: write | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Get Version numbers | |
run: | | |
echo "code_version=$(cat VERSION)" >> $GITHUB_ENV | |
echo "pypi_version=$(./dev_resources/scripts/get_latest_pypi_version.py)" >> $GITHUB_ENV | |
# - name: Setup Python | |
# uses: actions/setup-python@v3 | |
# with: | |
# python-version: '3.9' | |
# | |
# - name: Upgrade pip | |
# run: | | |
# # install pip=>20.1 to use "pip cache dir" | |
# python3 -m pip install --upgrade pip | |
# | |
# - name: Get pip cache dir | |
# id: pip-cache | |
# run: echo "::set-output name=dir::$(pip cache dir)" | |
# | |
# - name: Cache dependencies | |
# uses: actions/cache@v3 | |
# with: | |
# path: ${{ steps.pip-cache.outputs.dir }} | |
# key: ${{ runner.os }}-pip-${{ hashFiles('./requirements-dev.txt') }} | |
# restore-keys: | | |
# ${{ runner.os }}-pip- | |
# | |
# - name: Install dependencies | |
# run: | | |
# pip install -r requirements-dev.txt | |
# pip install . | |
# | |
# - name: Sphinx build | |
# run: | | |
# rm dev_resources/docs/IQM_Vis.* | |
# sphinx-apidoc -o dev_resources/docs IQM_Vis | |
# cd dev_resources/docs | |
# make clean html | |
# make html | |
- name: Deploy | |
# if: env.code_version != env.pypi_version | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
publish_branch: gh-pages | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: dev_resources/docs/_build/html |