fix: use pull_request_target for docs workflow to access secrets from fork PRs
The update-docs workflow intermittently failed with "Input required and not supplied: token" because pull_request events from fork PRs don't have access to repository secrets. Switching to pull_request_target runs the workflow in the base repo's context, ensuring secrets are always available. This is safe since the workflow only runs on already-merged PRs.
This commit is contained in:
2
.github/workflows/update-docs.yml
vendored
2
.github/workflows/update-docs.yml
vendored
@@ -1,7 +1,7 @@
|
||||
name: Update Documentation on PR Merge
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
pull_request_target:
|
||||
types: [closed]
|
||||
branches: [main]
|
||||
paths:
|
||||
|
||||
Reference in New Issue
Block a user