Inspect authoritative Git remote state

This commit is contained in:
2026-10-05 18:04:58 +00:00
parent 617c243923
commit 7d2c0c10d4
4 changed files with 562 additions and 1 deletions

View File

@@ -17,6 +17,8 @@ Implemented internal packages:
- `internal/candidate` captures and validates one clean local candidate, checks
its committed release note and local tag state, runs validation once, and
rechecks mutable repository state.
- `internal/git` resolves one effective push destination, applies it to a
command-scoped remote, and reads exact authoritative branch and tag refs.
- `cmd/releasekit/internal/cli` parses implemented commands, loads strict JSON
profiles, and adapts configured checks to the process runner.

View File

@@ -567,7 +567,7 @@ diagnostic. Temporary Git repositories cover the acceptance cases; offline
## Stage 6: Resolve and inspect the authoritative endpoint
Status: Pending. Depends on Stage 5.
Status: Complete. Depends on Stage 5.
1. Implement effective push-URL capture, command-scoped remote configuration,
matching read/write resolution, and endpoint rechecks described above.
@@ -581,6 +581,14 @@ ordinary URL rewrites, multiple push destinations, missing main, conflicting
tags, main ahead/behind the candidate, endpoint changes, and remote failure.
Queries leave local tags, persistent remote configuration, and remote refs intact.
Evidence: `internal/git` captures effective push destinations through Git,
rejects multiple distinct destinations, verifies scoped URL rewriting, and
queries exact main and version-tag refs. A candidate check requires main to
equal the captured commit and the version tag to be absent. Local bare remote
tests cover separate fetch/push URLs, both rewrite modes, missing main, an
existing tag, main ahead and behind, endpoint changes, unreadable remote state,
and unchanged persistent config and refs.
## Stage 7: Create and push the exact annotated tag
Status: Pending. Depends on Stage 6.