-
Notifications
You must be signed in to change notification settings - Fork 1
78 lines (63 loc) · 2.06 KB
/
sync.yml
File metadata and controls
78 lines (63 loc) · 2.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Sync Documentation
on:
repository_dispatch:
types: [repo-updated]
schedule:
- cron: '0 9 * * 1' # Every Monday 9 AM UTC
workflow_dispatch:
inputs:
repo:
description: 'Repo to update (or "all" for full rebuild)'
default: 'all'
permissions:
contents: write
pages: write
id-token: write
concurrency:
group: docs-deploy
cancel-in-progress: true
jobs:
sync-and-deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deploy.outputs.page_url }}
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v4
with:
version: "latest"
- name: Install dependencies
run: uv sync --extra llm
- name: Sync READMEs
run: uv run python scripts/sync_readmes.py
- name: Aggregate changelogs
run: uv run python scripts/aggregate_changelog.py
- name: Generate What's New
run: uv run python scripts/generate_whats_new.py
env:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build architecture overview
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
run: uv run python scripts/build_architecture.py
env:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
- name: Validate
run: uv run python scripts/validate_docs.py
- name: Build MkDocs site
run: uv run mkdocs build --strict 2>&1 || uv run mkdocs build
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: site/
- name: Deploy to GitHub Pages
id: deploy
uses: actions/deploy-pages@v4
- name: Commit updated docs source
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add docs/
git diff --staged --quiet || git commit -m "docs: auto-sync documentation [skip ci]"
git push