docs #274
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
name: docs | |
on: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]+' | |
- 'v[0-9]+.[0-9]+.[0-9]+a[0-9]+' | |
- 'v[0-9]+.[0-9]+.[0-9]+b[0-9]+' | |
- 'v[0-9]+.[0-9]+.[0-9]+rc[0-9]+' | |
workflow_dispatch: | |
inputs: | |
target: | |
description: 'Site to build and deploy' | |
type: choice | |
options: | |
- dev | |
- main | |
- dryrun | |
required: true | |
default: dryrun | |
schedule: | |
- cron: '0 15 * * SUN' | |
jobs: | |
conda_build_docs: | |
name: Documentation:conda | |
runs-on: 'ubuntu-latest' | |
timeout-minutes: 120 | |
defaults: | |
run: | |
shell: bash -l {0} | |
env: | |
DESC: "Documentation build" | |
MPLBACKEND: "Agg" | |
MOZ_HEADLESS: 1 | |
DISPLAY: ":99.0" | |
steps: | |
- uses: holoviz-dev/holoviz_tasks/install@v0.1a19 | |
with: | |
name: Documentation | |
python-version: "3.11" | |
channels: pyviz,conda-forge,nodefaults | |
envs: "-o doc -o examples -o geo -o graphviz" | |
cache: true | |
conda-update: true | |
- name: Set and echo git ref | |
id: vars | |
run: | | |
echo "Deploying from ref ${GITHUB_REF#refs/*/}" | |
echo "tag=${GITHUB_REF#refs/*/}" >> $GITHUB_OUTPUT | |
- name: bokeh sampledata | |
run: | | |
conda activate test-environment | |
bokeh sampledata | |
- name: generate rst | |
run: | | |
conda activate test-environment | |
nbsite generate-rst --org holoviz --project-name hvplot | |
- name: build docs | |
run: | | |
conda activate test-environment | |
nbsite build --what=html --output=builtdocs --org holoviz --project-name hvplot | |
- name: report failure | |
if: failure() | |
run: cat /tmp/sphinx-*.log | tail -n 100 | |
- name: Deploy dev | |
uses: peaceiris/actions-gh-pages@v3 | |
if: | | |
(github.event_name == 'workflow_dispatch' && github.event.inputs.target == 'dev') || | |
(github.event_name == 'push' && (contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc'))) | |
with: | |
personal_token: ${{ secrets.ACCESS_TOKEN }} | |
external_repository: holoviz-dev/hvplot | |
publish_dir: ./builtdocs | |
force_orphan: true | |
- name: Deploy main | |
if: | | |
(github.event_name == 'workflow_dispatch' && github.event.inputs.target == 'main') || | |
(github.event_name == 'push' && !(contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc'))) | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./builtdocs | |
cname: hvplot.holoviz.org | |
force_orphan: true | |
pip_build_docs: | |
name: Documentation:pip | |
runs-on: 'ubuntu-latest' | |
timeout-minutes: 120 | |
defaults: | |
run: | |
shell: bash -l {0} | |
env: | |
DESC: "Documentation build" | |
MPLBACKEND: "Agg" | |
MOZ_HEADLESS: 1 | |
DISPLAY: ":99.0" | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: install | |
run: pip install ."[doc, examples, geo]" | |
- name: pip list | |
run: pip list | |
- name: Set and echo git ref | |
id: vars | |
run: | | |
echo "Deploying from ref ${GITHUB_REF#refs/*/}" | |
echo "tag=${GITHUB_REF#refs/*/}" >> $GITHUB_OUTPUT | |
- name: bokeh sampledata | |
run: | | |
conda activate test-environment | |
bokeh sampledata | |
- name: generate rst | |
run: | | |
conda activate test-environment | |
nbsite generate-rst --org holoviz --project-name hvplot | |
- name: build docs | |
run: | | |
conda activate test-environment | |
nbsite build --what=html --output=builtdocs --org holoviz --project-name hvplot | |
- name: report failure | |
if: failure() | |
run: cat /tmp/sphinx-*.log | tail -n 100 |