mirror of
https://github.com/Yamato-Security/WELA.git
synced 2026-11-02 19:28:19 +01:00
Updates GitHub Actions to their latest releases and switches .github/workflows/docs.yml from floating major tags to commit-SHA pins, so every actions/* reference is pinned by SHA with a version comment (matching the convention used in the other workflows). - actions/checkout v6.0.2 -> v7.0.1 (docs.yml was already @v7) - actions/setup-python v6 / v6.3.0 -> v7.1.0 - actions/setup-node v6.4.0 -> v7.1.0 - actions/upload-artifact v7.0.1 -> v7.0.2 - actions/configure-pages -> v6.0.0 (SHA-pinned) - actions/upload-pages-artifact -> v5.0.0 (SHA-pinned) - actions/deploy-pages -> v5.0.1 (SHA-pinned) peter-evans/create-pull-request (v8.1.1) and peter-evans/enable-pull-request-automerge (v3.0.0) are already on their latest releases and left unchanged. Safe for our usage: checkout v7 only changes pull_request_target / workflow_run behavior (unused here); setup-python v7 drops the unused pip-install input (both usages pass only python-version / cache). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
67 lines
1.7 KiB
YAML
67 lines
1.7 KiB
YAML
name: Deploy docs to GitHub Pages
|
|
|
|
# Build the Material for MkDocs site in website/ and publish it to GitHub Pages.
|
|
# One-time setup: Settings -> Pages -> Source: "GitHub Actions".
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- "website/**"
|
|
- "CHANGELOG.md"
|
|
- "CHANGELOG-Japanese.md"
|
|
- ".github/workflows/docs.yml"
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: read
|
|
pages: write
|
|
id-token: write
|
|
|
|
concurrency:
|
|
group: pages
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
with:
|
|
python-version: "3.x"
|
|
cache: pip
|
|
|
|
- name: Install dependencies
|
|
run: pip install -r website/requirements.txt
|
|
|
|
- name: Sync changelog into docs
|
|
run: python website/scripts/sync_changelog.py
|
|
|
|
- name: Build site (strict)
|
|
run: mkdocs build --strict --config-file website/mkdocs.yml
|
|
|
|
- name: Configure Pages
|
|
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
|
|
with:
|
|
path: website/site
|
|
|
|
deploy:
|
|
needs: build
|
|
runs-on: ubuntu-latest
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
steps:
|
|
- name: Deploy to GitHub Pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346 # v5.0.1
|