Update 2023_lhc.md #928
Workflow file for this run
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
# Build documentation and upload to gh-pages | |
name: Ensure documentation builds after commits | |
defaults: | |
run: | |
shell: bash | |
on: [push, pull_request] # Runs on all push events to any branch | |
jobs: | |
documentation: | |
name: ${{ matrix.os }} / ${{ matrix.python-version }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python-version: [3.8] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: 'pip' | |
cache-dependency-path: '**/requirements.txt' | |
- name: Upgrade pip, setuptools and wheel | |
run: python -m pip install --upgrade pip setuptools wheel | |
- name: Install dependencies | |
run: python -m pip install -r requirements.txt | |
- name: Build documentation | |
run: python -m mkdocs build -d ./doc_build | |
- name: Upload build artifacts # upload artifacts so PR reviewers can have a quick look without building the branch locally | |
uses: actions/upload-artifact@v3 | |
if: success() && github.event_name == 'pull_request' | |
with: | |
name: site-build | |
path: doc_build | |
retention-days: 5 |