mirror of
https://github.com/semantica-agi/semantica.git
synced 2026-08-29 04:26:20 +00:00
Bumps [actions/configure-pages](https://github.com/actions/configure-pages) from 4 to 6. - [Release notes](https://github.com/actions/configure-pages/releases) - [Commits](https://github.com/actions/configure-pages/compare/v4...v6) --- updated-dependencies: - dependency-name: actions/configure-pages dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
81 lines
1.9 KiB
YAML
81 lines
1.9 KiB
YAML
name: Build and Deploy Documentation
|
|
|
|
# This workflow builds the documentation site and deploys it to GitHub Pages
|
|
# It runs when changes are pushed to the 'docs' folder on the main branch
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- 'docs/**'
|
|
- 'mkdocs.yml'
|
|
- 'requirements-docs.txt'
|
|
- 'CHANGELOG.md'
|
|
- 'RELEASE.md'
|
|
release:
|
|
types: [published]
|
|
workflow_dispatch:
|
|
|
|
# Permissions needed to deploy to GitHub Pages
|
|
permissions:
|
|
contents: read
|
|
pages: write
|
|
id-token: write
|
|
|
|
# Prevent concurrent deployments
|
|
concurrency:
|
|
group: "pages"
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
build:
|
|
name: Build Documentation
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Install documentation dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install -r requirements-docs.txt
|
|
|
|
- name: Build documentation
|
|
# Builds the static site using MkDocs
|
|
run: mkdocs build --strict
|
|
|
|
- name: Check for broken links
|
|
# Optional: checks if any links in the docs are broken
|
|
run: |
|
|
pip install linkchecker || echo "Skipping link check"
|
|
if [ -d "site" ]; then
|
|
linkchecker site/ --check-extern || echo "Link check completed"
|
|
fi
|
|
continue-on-error: true
|
|
|
|
- name: Setup Pages
|
|
uses: actions/configure-pages@v6
|
|
continue-on-error: true
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-pages-artifact@v3
|
|
with:
|
|
path: ./site
|
|
|
|
deploy:
|
|
name: Deploy to GitHub Pages
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
runs-on: ubuntu-latest
|
|
needs: build
|
|
steps:
|
|
- name: Deploy to GitHub Pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@v4
|