Conversation
…ss-repo setup instructions Agent-Logs-Url: https://github.com/github/gh-aw/sessions/ae097dd6-28a0-42c5-8241-4ef1e7663220 Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Updates reference documentation to reflect that push-to-pull-request-branch supports cross-repository usage via target-repo, and documents the required checkout setup (including the path: requirement).
Changes:
- Update safe outputs summary text to remove “same-repo only” limitation for
push-to-pull-request-branch. - Extend
push-to-pull-request-branchdocs to includetarget-repo/allowed-reposand a new cross-repo setup section with an example. - Add a cross-repository docs callout describing the checkout requirement and linking to the detailed setup.
Show a summary per file
| File | Description |
|---|---|
| docs/src/content/docs/reference/safe-outputs.md | Updates the safe output type summary to reflect cross-repo support for PR branch pushes. |
| docs/src/content/docs/reference/safe-outputs-pull-requests.md | Documents cross-repo configuration fields and adds a “Cross-repo usage” section + example. |
| docs/src/content/docs/reference/cross-repository.md | Adds an explicit checkout requirement callout for cross-repo PR-branch pushes and links to examples. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 3/3 changed files
- Comments generated: 1
| - fetch-depth: 0 # checkout current (source) repo | ||
| - repository: org/target-repo | ||
| path: ./target-repo # must set path for cross-repo checkout | ||
| github-token: ${{ secrets.CROSS_REPO_PAT }} | ||
| fetch: ["refs/pulls/open/*"] # fetch all open PR branches | ||
|
|
There was a problem hiding this comment.
In the cross-repo example, the org/target-repo checkout uses fetch: ["refs/pulls/open/*"] but does not set fetch-depth: 0. The checkout reference docs recommend fetch-depth: 0 when fetching additional refs to ensure full history/PR details are available; with a shallow clone the push-to-PR flow may not have enough history to inspect or apply changes reliably. Consider adding fetch-depth: 0 to the target repo checkout entry as well.
push-to-pull-request-branchnow supports cross-repo usage viatarget-repo, but the docs still said "same-repo only". This PR updates the reference docs to reflect that and explains the checkout requirement.Changes
safe-outputs.md— replace"same-repo only"with"cross-repo supported via \target-repo` when the target repository is checked out"` in the output type summary tablesafe-outputs-pull-requests.mdtarget-repoandallowed-reposfields to thepush-to-pull-request-branchconfig blockpath:checkout requirement and providing a minimal working example:cross-repository.md— add Checkout Requirement forpush-to-pull-request-branchcallout in the Cross-Repository Safe Outputs section, linking to the new subsection and the existing scheduled-push example