|
|
@@ -1,32 +1,35 @@
|
|
|
-# Workflow for building and deploying a Jekyll site to GitHub Pages
|
|
|
-name: Deploy Jekyll with GitHub Pages dependencies preinstalled
|
|
|
+name: Build & deploy Jekyll documentation
|
|
|
|
|
|
on:
|
|
|
- # Runs on pushes targeting the default branch
|
|
|
+ # Runs on pushes and PRs targeting the default branch
|
|
|
push:
|
|
|
branches: ["edge"]
|
|
|
paths:
|
|
|
- 'docs/**'
|
|
|
+ - '.github/workflows/docs-build-deploy.yml'
|
|
|
+ pull_request:
|
|
|
+ branches: ["edge"]
|
|
|
+ paths:
|
|
|
+ - 'docs/**'
|
|
|
+ - '.github/workflows/docs-build-deploy.yml'
|
|
|
|
|
|
- # Allows you to run this workflow manually from the Actions tab
|
|
|
+ # Allows you to run this workflow manually from the Actions tab (deploy)
|
|
|
workflow_dispatch:
|
|
|
|
|
|
permissions: {}
|
|
|
|
|
|
-# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
|
|
|
-# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
|
|
|
concurrency:
|
|
|
- group: "pages"
|
|
|
+ group: docs-build-deploy-${{ github.ref }}
|
|
|
cancel-in-progress: false
|
|
|
|
|
|
jobs:
|
|
|
- # Build job
|
|
|
+ # Build job (the only job that runs in PRs to test the build)
|
|
|
build:
|
|
|
name: build
|
|
|
- runs-on: ubuntu-latest
|
|
|
+ runs-on: ubuntu-26.04
|
|
|
permissions:
|
|
|
contents: read
|
|
|
- pages: write # For preparing the page deployment
|
|
|
+ pages: read # For the "Setup Pages" step
|
|
|
steps:
|
|
|
- name: Checkout
|
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
|
@@ -34,27 +37,31 @@ jobs:
|
|
|
persist-credentials: false
|
|
|
- name: Setup Ruby
|
|
|
uses: ruby/setup-ruby@7f797815d8adceb1c412e7abefdd1ab4abc47a5f # v1.335.0
|
|
|
+ env:
|
|
|
+ BUNDLE_FROZEN: true # Always respect Gemfile.lock (explicit)
|
|
|
with:
|
|
|
ruby-version: '3.4.9'
|
|
|
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
|
|
cache-version: 1 # Increment this number if you need to re-download cached gems
|
|
|
working-directory: docs
|
|
|
- - name: Setup Pages
|
|
|
- uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
|
|
|
- name: Build with Jekyll
|
|
|
run: |
|
|
|
cd docs
|
|
|
bundle exec jekyll build --destination ../_site
|
|
|
+ - name: Setup Pages
|
|
|
+ uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
|
|
|
+ if: ${{ github.ref == 'refs/heads/edge' }}
|
|
|
- name: Upload artifact
|
|
|
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
|
|
|
|
|
|
- # Deployment job
|
|
|
+ # Deployment job (skipped in PRs)
|
|
|
deploy:
|
|
|
name: deploy
|
|
|
+ if: ${{ github.ref == 'refs/heads/edge' }}
|
|
|
environment:
|
|
|
name: github-pages
|
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
|
- runs-on: ubuntu-latest
|
|
|
+ runs-on: ubuntu-26.04
|
|
|
permissions:
|
|
|
pages: write # For deploying the page
|
|
|
id-token: write # For authorizing the deployment
|