[TRUNK-17582] Add Multiple Repositories and Forks guide for Flaky Tests#445
[TRUNK-17582] Add Multiple Repositories and Forks guide for Flaky Tests#445samgutentag wants to merge 2 commits intomainfrom
Conversation
Document how Trunk identifies repos by git remote URL (not API token), enabling safe use of the same org token across forks. Covers repo identification, fork workflows, --repo-url overrides, and common scenarios like private forks, multiple forks, and monorepo variants. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Claude finished @pat-trunk-io's task in 2m 7s —— View job PR Review: Multiple Repositories and Forks guide
Overall, this is a well-structured and clearly written guide that directly addresses a real customer question. The content is accurate, well-organized, and the examples are helpful. A few minor issues noted: Issues found:
What looks good:
The undocumented flags (item 3) is the most important thing to verify before merging. Fix this → |
|
|
||
| # Multiple Repositories and Forks | ||
|
|
||
| Trunk Flaky Tests identifies repositories by their **git remote URL**, not by the API token. You can safely use the same organization API token across multiple repositories -- including forks -- without mixing test results. |
There was a problem hiding this comment.
Minor style nit: double hyphens (--) used as em dashes can look informal in docs. Consider using an actual em dash (—) or rewording to avoid it:
| Trunk Flaky Tests identifies repositories by their **git remote URL**, not by the API token. You can safely use the same organization API token across multiple repositories -- including forks -- without mixing test results. | |
| Trunk Flaky Tests identifies repositories by their **git remote URL**, not by the API token. You can safely use the same organization API token across multiple repositories — including forks — without mixing test results. |
|
|
||
| ## Overriding Repository Detection | ||
|
|
||
| In some cases you may need to manually specify the repository URL: |
There was a problem hiding this comment.
Missing comma after the introductory phrase:
| In some cases you may need to manually specify the repository URL: | |
| In some cases, you may need to manually specify the repository URL: |
|
|
||
| ### Uploading Without a Git Checkout | ||
|
|
||
| For CI environments where you download build artifacts instead of checking out the repository, use the `--use-uncloned-repo` flag along with the required metadata: |
There was a problem hiding this comment.
The --use-uncloned-repo and --repo-head-author-name flags referenced in the code example below (lines 90 and 94) do not appear to be documented in the Trunk Analytics CLI reference. Please verify these flags exist in the current CLI and consider adding them to the reference page, or remove them from this example if they aren't valid flags.
There was a problem hiding this comment.
This link goes to Not Found
There was a problem hiding this comment.
I meant your link you posted https://github.com/trunk-io/docs/uploader.md#full-command-reference gets me not found
|
Claude finished @pat-trunk-io's task in 2m 7s —— View job PR Review: Multiple Repositories and Forks guide
This is a well-structured, clearly written guide that addresses a real customer question. The content and organization are solid. Three issues remain unaddressed from the previous review: Issues:
Clarification on the broken link @pat-trunk-io reported: The relative link What looks good:
|
Summary
flaky-tests/get-started/multiple-repositories.mdexplaining how Trunk identifies repositories by git remote URL, not API token--repo-urloverrides, uploading without git checkout, and common scenarios (private forks, multiple forks, monorepo variants)summary.mdto add the page under Getting Started after CI ProvidersLinear
Context
Customer question in Slack about whether using the same API key for a private fork would mix test results. Answer: repos are identified by git remote URL (host/owner/name), so forks with different remotes are automatically separate.
Test plan
summary.mdentry appears in correct location in sidebar--repo-urland--use-uncloned-repoflag documentation matches current CLI behavior🤖 Generated with Claude Code