Files
HaloKeymind/.github/workflows/github-pages.yml
T

45 lines
1.3 KiB
YAML

name: Build and deploy Docs site to GitHub Pages
on:
workflow_dispatch:
push:
branches:
- main
- keymindCascade
permissions:
contents: write
jobs:
github-pages:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v6
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: '3.13'
- name: Build
env:
MKDOCS_SITE_URL: https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}/
MKDOCS_REPO_NAME: ${{ github.repository }}
MKDOCS_REPO_URL: https://github.com/${{ github.repository }}/
MKDOCS_EDIT_URI: edit/${{ github.ref_name }}/docs/
run: |
pip install mkdocs-material
mkdocs build
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4.1.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# Preserve the upstream custom domain, but let forks publish at their
# normal <owner>.github.io/<repo>/ URL without claiming that domain.
cname: ${{ github.repository_owner == 'meshcore-dev' && 'docs.meshcore.io' || '' }}
publish_dir: ./site
publish_branch: 'gh-pages'