Skip to content

fix(trail): deprecate trail resume --repo - #2829

Merged
gtrrz-victor merged 2 commits into
mainfrom
victor/trail-resume-repo-forge
Oct 20, 2026
Merged

gtrrz-victor merged 2 commits into
mainfrom
victor/trail-resume-repo-forge

Conversation

@gtrrz-victor

@gtrrz-victor gtrrz-victor commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

@gtrrz-victor
gtrrz-victor requested a review from a team as a code owner October 20, 2026 07:54
Copilot AI balanced review requested due to automatic review settings October 20, 2026 07:54

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

馃煝 Approval recommended

The focused changes preserve repository and branch safeguards, have regression coverage, and have no identified blocking issues.

No open issues 馃帀

What changed in this PR

Makes trail resume --repo forge-aware so Entire-hosted checkouts accept valid repository assertions and produce usable resume commands.

Changes:

  • Accept bare owner/repo on any forge while keeping explicit forge assertions strict.
  • Forge-qualify printed repository references and suggest corrected commands for forge-only mismatches.
  • Add regression tests for parsing, validation, suggestions, and Entire-hosted output.
File Description
cmd/鈥媏ntire/鈥媍li/鈥媡rail_resume_cmd.go Updates repository assertions, output, help, and mismatch suggestions.
cmd/鈥媏ntire/鈥媍li/鈥媡rail_resume_cmd_test.go Tests forge-aware parsing and validation.
cmd/鈥媏ntire/鈥媍li/鈥媡rail_legacy_cmd_test.go Tests corrected commands and Entire-hosted resume behavior.

Review effort: Balanced

`trail resume --repo` asserted the checkout's repository, but a bare
owner/repo was parsed as GitHub, so commands copied for Entire-hosted
repositories failed with "targets repository entirehq/entire-api, but the
current checkout is entirehq/entire-api". Resume always acts on the local
clone and --branch already guards against pasting into the wrong one.

The flag is now hidden and ignored, with a deprecation notice on stderr
so previously copied commands keep working, and the printed resume and
finding commands no longer include it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Entire-Checkpoint: 01M5CFQ1GJE5HND02P7Y6DQPCB
@gtrrz-victor
gtrrz-victor force-pushed the victor/trail-resume-repo-forge branch from 4722709 to 76211a4 Compare October 20, 2026 11:04
@gtrrz-victor gtrrz-victor changed the title fix(trail): match trail resume --repo on the checkout's forge fix(trail): deprecate trail resume --repo Oct 20, 2026
The early origin lookup, the repoFullName parameter and the `repo` field
of `trail resume --no-resume --json` existed only for the removed --repo
assertion. The working contexts already resolve origin themselves, so
remove them, rename the builder to buildTrailResumeContext, and drop the
test that covered the repo-aware builder.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Entire-Checkpoint: 01M5CJ0SCVTPK6GZVYEFGHQHBX
@gtrrz-victor
gtrrz-victor merged commit 7d659a9 into main Oct 20, 2026
21 checks passed
@gtrrz-victor
gtrrz-victor deleted the victor/trail-resume-repo-forge branch October 20, 2026 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants