Skip to content

Replace pull_request_target in PR helper with split workflows - #4878

Open
xiang17 wants to merge 1 commit into
mainfrom
xiang17/migrate-pull_request_target
Open

xiang17 wants to merge 1 commit into
mainfrom
xiang17/migrate-pull_request_target

Conversation

@xiang17

@xiang17 xiang17 commented Oct 22, 2026

Copy link
Copy Markdown
Member

Remove pull_request_target from the Dependabot helper while preserving
automatic dependency lockfile and license updates.

  • Generate a text patch in a read-only pull_request workflow, without
    App credentials.
  • Publish the patch through a separate workflow_run workflow that
    validates the source run, open Dependabot PR, and current head SHA.
  • Apply changes in an isolated Git index without checking out or executing
    PR code in the privileged workflow.
  • Restrict changes to regular, nonexecutable lock/license files; reject
    binary patches and patches larger than 8 MiB.
  • Push using the existing GitHub App token so normal PR CI still runs.
    Do not force-push.
  • Skip uploading and publishing when no generated changes are needed.
    Cancel superseded producer runs for the same PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant