Skip to content

Commit a56e91e

Browse files
authored
docs: notify Testably.Site when documentation changes (#755)
Adds a workflow that fires the extension-documentation-updated-event repository dispatch at Testably/Testably.Site whenever Docs/pages/** changes on main. Site responds by re-fetching this repo'\''s docs and redeploying https://docs.testably.org. Requires a SITE_DISPATCH_TOKEN secret with repo write on Testably/Testably.Site.
1 parent 812a93f commit a56e91e

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Notify Docs Site
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
paths:
7+
- 'Docs/pages/**'
8+
workflow_dispatch:
9+
10+
jobs:
11+
dispatch:
12+
if: github.ref == 'refs/heads/main'
13+
name: Trigger Site rebuild
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Dispatch extension-documentation-updated-event to Testably/Testably.Site
17+
uses: peter-evans/repository-dispatch@v3
18+
with:
19+
token: ${{ secrets.SITE_DISPATCH_TOKEN }}
20+
repository: Testably/Testably.Site
21+
event-type: extension-documentation-updated-event
22+
client-payload: '{"source": "${{ github.repository }}", "sha": "${{ github.sha }}"}'

0 commit comments

Comments
 (0)