3cf0bcdec7
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
88 lines
2.6 KiB
YAML
88 lines
2.6 KiB
YAML
name: Rebuild Skills Marketplace
|
|
|
|
# This workflow rebuilds the documentation site to pull in new skills
|
|
# from the Agent-Skills repository. It runs:
|
|
# 1. Every hour on a schedule
|
|
# 2. On manual trigger for testing
|
|
|
|
on:
|
|
schedule:
|
|
# Run every hour at minute 15
|
|
- cron: '15 * * * *'
|
|
workflow_dispatch:
|
|
inputs:
|
|
reason:
|
|
description: 'Reason for manual rebuild'
|
|
required: false
|
|
default: 'Manual trigger'
|
|
|
|
concurrency:
|
|
group: pages
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
rebuild-docs:
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'aaif-goose/goose'
|
|
permissions:
|
|
contents: read
|
|
pages: write
|
|
id-token: write
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
|
|
steps:
|
|
- name: Log trigger info
|
|
env:
|
|
TRIGGER: ${{ github.event_name }}
|
|
REASON: ${{ github.event.inputs.reason }}
|
|
run: |
|
|
echo "Triggered by: $TRIGGER"
|
|
echo "Time: $(date -u)"
|
|
if [ "$TRIGGER" == "workflow_dispatch" ]; then
|
|
echo "Reason: $REASON"
|
|
fi
|
|
|
|
- name: Checkout the branch
|
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
|
with:
|
|
node-version: 20
|
|
|
|
- name: Cache Node.js modules (documentation)
|
|
uses: actions/cache@8b402f58fbc84540c8b491a91e594a4576fec3d7 # v5.0.2
|
|
with:
|
|
path: ./documentation/node_modules
|
|
key: ${{ runner.os }}-documentation-${{ hashFiles('./documentation/package-lock.json') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-documentation-
|
|
|
|
- name: Install dependencies and build docs
|
|
working-directory: ./documentation
|
|
env:
|
|
INKEEP_API_KEY: ${{ secrets.INKEEP_API_KEY }}
|
|
INKEEP_INTEGRATION_ID: ${{ secrets.INKEEP_INTEGRATION_ID }}
|
|
INKEEP_ORG_ID: ${{ secrets.INKEEP_ORG_ID }}
|
|
run: |
|
|
npm install
|
|
npm run build
|
|
|
|
- name: Verify docs map was generated
|
|
working-directory: ./documentation
|
|
run: ./scripts/verify-build.sh
|
|
|
|
- name: Configure GitHub Pages
|
|
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
|
|
|
|
- name: Upload GitHub Pages artifact
|
|
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
|
|
with:
|
|
path: documentation/build
|
|
|
|
- name: Deploy to GitHub Pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
|