Skip to content

Commit 008f309

Browse files
committed
Add a workflow to trigger docs generation
1 parent dfbf2ff commit 008f309

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

.github/workflows/trigger_docs.yaml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Trigger Docs Generation Workflow
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
workflow_dispatch:
8+
9+
jobs:
10+
trigger:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Generate a token
15+
id: generate-token
16+
uses: actions/create-github-app-token@v1
17+
with:
18+
app-id: ${{ secrets.INTERNAL_GHA_APP_ID }}
19+
private-key: ${{ secrets.INTERNAL_GHA_APP_PRIVATE_KEY }}
20+
21+
- name: Dispatch workflow
22+
uses: octokit/request-action@v2.x
23+
with:
24+
route: POST /repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches
25+
owner: polarsource
26+
repo: polar
27+
workflow_id: code_samples.yml
28+
env:
29+
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}

0 commit comments

Comments
 (0)