Skip to content

Commit 0050ae1

Browse files
committed
add sync-docs workflow
1 parent cd53d5a commit 0050ae1

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/sync-docs.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Sync docs
2+
3+
on:
4+
# Listen to a repository dispatch event by the name of `dispatch-event`
5+
repository_dispatch:
6+
types: [sync-request]
7+
8+
jobs:
9+
log:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: pnpm/action-setup@v4
14+
- uses: actions/setup-node@v4
15+
with:
16+
node-version: 22
17+
cache: pnpm
18+
- run: pnpm install --frozen-lockfile
19+
20+
- name: Sync
21+
run: cd apps/svelte.dev && pnpm sync-docs -p ${{ github.event.client_payload.package }}
22+
23+
- name: Create or update pull request
24+
uses: peter-evans/create-pull-request@v7
25+
with:
26+
commit-message: sync ${{ github.event.client_payload.package }} docs
27+
title: Sync ${{ github.event.client_payload.package }}
28+
body: This is an automated pull request
29+
branch: sync:${{ github.event.client_payload.package }}
30+
base: main

0 commit comments

Comments
 (0)