Skip to content

Pages

Pages #12

Workflow file for this run

name: Pages
# The site is docs/ rendered by MkDocs, republished when a page or the site
# configuration changes on main. --strict: a broken link fails the deployment.
on:
push:
branches: [main]
paths:
- 'docs/**'
- 'mkdocs.yml'
- 'docs-requirements.txt'
- 'scripts/mkdocs_repo_links.py'
- 'scripts/mkdocs_landing.py'
- 'scripts/mkdocs_header_menu.py'
- 'overrides/**'
- '.github/workflows/pages.yml'
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
# One deployment at a time; cancelling one in flight would leave the site behind.
concurrency:
group: pages
cancel-in-progress: false
jobs:
build:
name: Documentation site
# The site is published from Open-MBEE/OpenSysML; a fork would deploy the same
# pages under its own domain.
if: github.repository == 'Open-MBEE/OpenSysML'
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: pip
cache-dependency-path: docs-requirements.txt
- name: Install documentation toolchain
run: make docs-install
- name: Configure GitHub Pages
uses: actions/configure-pages@v5
- name: Build documentation site
run: make docs
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: site
deploy:
name: Deploy to Pages
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy GitHub Pages
id: deployment
uses: actions/deploy-pages@v4