Skip to content

fix: disable Git terminal prompts so HTTPS remotes cannot block on credential input - #36

Merged
jishnuteegala merged 12 commits into
mainfrom
docs/quality-pass
Oct 10, 2026
Merged

jishnuteegala merged 12 commits into
mainfrom
docs/quality-pass

Conversation

@jishnuteegala

@jishnuteegala jishnuteegala commented Oct 8, 2026 •

Copy link
Copy Markdown
Owner

Summary

First-principles quality pass over every released surface (ticket: quality-pass-first-principles). One defect fix plus prose/metadata alignment; the re-audit follow-up added a project-local verification skill and a move-only refactor. No toolchain or release-machinery changes.

  • git subprocesses now run with GIT_TERMINAL_PROMPT=0 at both spawn sites, so an HTTPS remote without a credential helper fails fast ("terminal prompts disabled") instead of hanging on a prompt. SSH passphrases, host-key confirmations, and askpass helpers are unaffected and are now documented as such; hooks inherit the same environment.
  • Anti-slop pass: em dashes removed from --help output and README; -h, --help added to the flag table; --spacing added to llms.txt.
  • Channel descriptions aligned on the canonical string ("Commit and push changes in chunks to avoid SCM push size limits"); nfpm was the outlier.
  • install.sh points Windows POSIX shells (MINGW/MSYS/CYGWIN/UCRT64/CLANG) at winget install instead of a bare "unsupported operating system" error.
  • PUBLISHING-SETUP.md external-state column refreshed against live registries.
  • PRE-RELEASE-REVIEW.md deleted: its v0.1.0 gate is verified complete (branch protection on main requires test (ubuntu/macos/windows-latest) + release-checks), and three releases have shipped.
  • internal/cli/push.go extracted from run.go: push retry, transient-error classification, spacing, and ETA helpers moved verbatim; parseSpacing moved to cli.go beside its sole caller. AGENTS.md and develop-git-chunks ownership maps updated.
  • .agents/skills/verify-git-chunks/ added via create-verification-skill: Launch/Doctor/Drive/Evidence/Cleanup contract plus a four-feature map, proven end to end against scratch repos; the proof run caught and fixed a real helper defect. .agents/quality-pass-decisions.tsv records the re-audit and architecture decisions.
 internal/cli/
-├── git.go      # subprocesses inherited the prompt-capable environment
+├── git.go      # GIT_TERMINAL_PROMPT=0 at both spawn sites
-├── run.go      # orchestration + push delivery
+├── run.go      # validation, orchestration, resumability
+├── push.go     # retry, pacing, transient errors, ETA
 ├── cli.go      # argument parsing (+ parseSpacing) and exit mapping
 └── chunk.go    # deterministic planner (unchanged)

Evidence

  • Before: git subprocesses inherited the prompt-capable environment, so an HTTPS remote demanding credentials could block on a terminal prompt; push retry, spacing, and ETA logic was embedded in run.go; no project-local verification skill existed; this body lacked the pr-contract sections.
    After:
    $ go test -run TestGitSubprocessNeverPromptsForCredentials -count=1 -race -v ./internal/cli/
    --- PASS: TestGitSubprocessNeverPromptsForCredentials (0.14s)
    ok    github.com/jishnuteegala/git-chunks/internal/cli    1.783s
    
    The refactor is provably move-only: the internal/cli/run.go diff is 98 deletions, 0 additions, and the extracted block is byte-identical in push.go. The skill's own E2E run left doctor.txt, chunk-run.*, and index-guard.* under evidence/ after cleanup removed scratch/. Full gate output is in the Test plan.

Merge Danger

Door: two-way - a verbatim code relocation plus docs/metadata edits; revertible per commit, no data or schema change.

Blast Radius: CLI

Squash-merge caveat: the fix: title means release notes name only the credential-prompt fix; the refactor rides hidden via the refactor: trailer at the body bottom (release-please skips that type).

Test plan

  • gofmt -l cmd internal - clean
  • go vet ./... - clean
  • go test -count=1 -race ./... - ok (74s)
  • node --test scripts/*.test.mjs - 10/10 pass
  • bash -n scripts/install.sh scripts/uninstall.sh - clean
  • git diff --check - clean
  • go run github.com/goreleaser/goreleaser/v2@v2.17.0 check - 1 configuration file validated
  • E2E smoke per docs/testing.md: built binary chunked 2 files into 2 commits and pushed to a bare local remote with --spacing; remote history verified
  • New hermetic test TestGitSubprocessNeverPromptsForCredentials: local httptest server returns 401, git ls-remote fails with "terminal prompts disabled" (fresh -race run, 0.14s)
  • --help output manually inspected
  • External state verified live: git-chunks@0.3.0 on npm carries a provenance attestation; Chocolatey feed lists 0.1.0/0.2.0/0.3.0; winget-pkgs PRs #404270/#408446/#409137 merged; AUR git-chunks-bin at 0.3.0-1; Homebrew cask and Scoop manifest at 0.3.0; main branch protection requires the four documented checks
  • verify-git-chunks proven end to end: build + doctor (3/3), chunked-commits drive (two chunk commits, clean tree, empty index), index-guard exit 1 with staged file preserved; evidence survived cleanup
  • Refactor verified move-only: run.go shows 98 deletions, 0 additions; extracted block byte-identical in push.go
  • git ls-files --eol - all files i/lf; six-column TSV schema verified field-by-field

Review convergence

Reviewed by the reviewer subagent profile pinned to swe-2-max (the free-family reviewer mandated while the account has no paid quota; lead also ran swe-2-max, so the different-family rule is moot this pass). Original pass: 4 rounds, 6 -> 2 -> 1 -> 0 findings. Follow-up diff (verify skill, decision trail, push.go extraction): 4 rounds covering CRLF line endings, a deviating TSV schema, TZ-mislabeled timestamps, an impossible drive expectation, and stale line cites - driven to a lone doc-precision nit, since corrected.

Dispositions

Every live inventory item received exactly one disposition. Skills: 52 applied, 67 not-applicable (114 skills under ~/.agents/skills, the declarative-repo-setup and upload-secrets builtins, and 3 repo-local skills under .agents/skills; the inventory grew by one when verify-git-chunks was created and applied). A re-audit corrected 34 premature not-applicable calls; corrected entries are marked below.

Rules and inventory

Item Disposition
~/.agents/AGENTS.md rules (no em dash, sentence-per-line Markdown, no co-author, Conventional Commit PR, no inspiration or incident mentions) Applied throughout
Devin harness rules (type/short branch, PR body contract, reviewer on swe-2-max, pnpm-only, no pushes to main) Applied throughout
windsurf global_rules.md Not applicable - file is empty
factory/POLICY.md Applied: checkpoint policy honored; PR left unmerged for Checkpoint 2
factory/knowledge/quality-pass-scope.md + knowledge grep for git-chunks Applied: binding scope for this inventory; durable facts pulled before planning
Repo AGENTS.md Applied: non-interactive invariant scoped to HTTPS terminal prompts; ownership map gained push.go; project-skills index gained verify-git-chunks
Repo skills develop-git-chunks, release-git-chunks, verify-git-chunks Applied (counted under Skills)
.agents/skills/verify-git-chunks/ Applied: new - Launch/Doctor/Drive/Evidence/Cleanup contract + four-feature map, proven end to end
.agents/quality-pass-decisions.tsv Applied: new - six-column decision trail per show-me-your-work; timestamps verified against commit times
CONTEXT.md, PRODUCT.md, DESIGN.md, docs/adr/, docs/agents/ Not applicable - absent from the repo
README.md Applied: em dashes, --help row, prompt behavior and residual limits, channel status
llms.txt Applied: --spacing, prompt behavior
PUBLISHING-SETUP.md Applied: external-state column resynced to live registries
PRE-RELEASE-REVIEW.md Applied: deleted; its v0.1.0 gate verified complete
CHANGELOG.md Not applicable - release-please generated, never hand-edited
docs/testing.md Applied: bare-remote E2E smoke recipe executed
CLI help and flag text (internal/cli/cli.go) Applied: em dashes removed; parseSpacing relocated beside the --spacing callback
Git process boundary (internal/cli/git.go) Applied: GIT_TERMINAL_PROMPT=0 defect fix + hermetic behavioral test
internal/cli/run.go + internal/cli/push.go Applied: push-delivery mechanics extracted verbatim (98 deletions, 0 additions)
stdout/stderr and exit-code contract Audited, no change - implementation already matches the documented contract
.goreleaser.yaml Applied: nfpm description aligned; archive/package matrix audited, no change
scripts/install.sh, scripts/uninstall.sh Applied: Windows POSIX shells pointed at winget install; bash -n clean
scripts/publish-*, verify-artifacts.mjs, release-payloads.mjs, package-chocolatey.ps1 Audited, no change - deterministic and retryable; toolchain changes are non-goals
.github/workflows/{ci,publish,release-please}.yml Audited, no change - full-SHA action pinning and required check names verified
scripts/*.test.mjs Audited - 10/10 pass
Branch protection and Protect release tags ruleset Audited, verified live - main requires the four documented checks
Repo description and settings Audited - description wording flagged as an open item (repo setting, outside the diff)
External registries: npm, Chocolatey, winget-pkgs, AUR, Homebrew, Scoop Applied: all verified live at 0.3.0, prose synced
Accessibility baseline, site furniture, UI surfaces Not applicable - CLI tool, no UI artifact exists to measure
Factory ticket file Applied: status: built, dated factory-log entry with this PR

Skills: applied (52)

build (ticket router), plan (inventory shaping), implement (the push.go extraction), review (convergence loop above), verify (live-registry and repo-state checks), writing + unslop (prose standard, em-dash pass), test-audit (gated the credential-prompt test), engineering-principles (index); repo-local develop-git-chunks (gates, real-temp-repo rule), release-git-chunks (release-surface invariants), verify-git-chunks (created this pass, proven end to end).

Principle leaves exercised: principle-boundary-discipline (surfaces-only scope held), principle-fix-root-causes (the GIT_TERMINAL_PROMPT defect), principle-subtract-before-you-add (PRE-RELEASE-REVIEW.md deleted), principle-prove-it-works (behavioral test + live verification), principle-test-behavior-not-implementation (replaced the env-presence assertion), principle-minimize-reader-load, principle-never-block-on-the-human, principle-outcome-oriented-execution, principle-redesign-from-first-principles (the ticket itself), principle-foundational-thinking (surface-wide audit), principle-experience-first (fail-fast over silent hang), principle-encode-lessons-in-structure (verify skill + decision trail), principle-exhaust-the-design-space (three architecture candidates ranked), principle-model-the-domain (push-delivery domain named), principle-attack-the-premise (re-audit + auto-grill), principle-sequence-verifiable-units, principle-guard-the-context-window, principle-type-system-discipline (move verified by the compiler), principle-laziness-protocol (bare-remote verification over network remotes), principle-build-the-lever (durable verify skill), principle-make-operations-idempotent (re-runnable drives; resume semantics proven).

Re-audit corrections (34): create-verification-skill (generated + proved .agents/skills/verify-git-chunks/; "existing tests cover it" was wrong - the deliverable is a durable driving contract, not test coverage), verify-git-chunks (the artifact itself, executed end to end), write-skill + writing-for-agents (authored the skill to the agent-writing contract), improve-codebase-architecture (section-5 unattended factory mode; HTML report; push.go picked on deepening value vs blast radius), auto-grill (the sanctioned substitute for interactive grilling; decided D1-D5 on the refactor), codebase-design + domain-modeling (the deepening analysis and the named push-delivery domain - not "tech-stack non-goals"), investigate-implementation (candidate scan across internal/cli), implement ("surfaces only" went stale once the follow-up landed code), show-me (Summary visual vocabulary), show-me-your-work (.agents/quality-pass-decisions.tsv), pr (body contract: visual, Evidence, Merge Danger), blast-radius (Merge Danger classification), verify-claims (every claim re-checked by reviewer rounds and E2E proofs), compliance-sync (external-state resync), github-repo-setup (settings audited live), technical-writing (README/llms.txt/skill docs rewritten), deslop (stale release-gate doc and help-surface slop removed - distinct from unslop's prose style), debug + diagnosing-bugs (mkrepo helper defect root-caused during the skill's own E2E proof), and the 13 principle leaves listed after the original eight.

Skills: not applicable (67)

  • No UI artifact exists to drive or measure (verified - the repo ships a binary, not a rendered surface): custom-computer-use, design-inspiration, design-ui, impeccable, iterate-ui, make-interfaces-feel-better, markup-from-image, product-footers, prototype, react-doctor, sync-design-artifacts, tailwind-canonicalize, ui-preflight, visual-bug-report.
  • No X content: browse-x, import-x-history.
  • Interactive-by-design; the grilling function was served by auto-grill (counted in applied): grilling, grill-me, grill-with-docs, clean-room-deliberation, interrogate.
  • Explanation deliverables absent - they produce a conversation with an asking user; this pass's explanations live in README and AGENTS.md: explain, how, why, teach, wayfinder; voice (nothing published under the user's identity).
  • Factory/meta machinery - single-ticket execution inside an existing run, not a pipeline op: factory, factory-run, factory-retro, manage-skills, intake, reflect, session-review, handoff, to-spec, to-tickets, triage, write-issue, ideate, research, repo-explorer.
  • Harness/runtime mismatch: code-review + custom-code-review (Devin routes convergence to the reviewer profile), opencode-history, debug-opencode-sessions, orbit (opencode/GitLab tooling), clean-room-redesign (a verbatim relocation, not a from-scratch rebuild).
  • Pre-build design locks: architecture, program-design - no new seams, schemas, or signatures were introduced; the deepening scan ran through improve-codebase-architecture's unattended mode.
  • States that never arose: fix-ci-run (no failing run), resolving-merge-conflicts, tdd (fix landed with its test, not red-first), no-comments (Go code carries no comments to strip), maintain-verification-skill (created this pass, not maintained), install-anti-slop + setup-matt-pocock-skills (no skill installs), typescript-best-practices (Go repo), arena + swarm (single canonical path), humanizer (unslop covered the prose volume), production-readiness (release already live, no hosting change), release-engineering (toolchain a non-goal).
  • Principle leaves with no trigger: principle-migrate-callers-then-delete-legacy-apis, principle-separate-before-serializing-shared-state.
  • Builtins: declarative-repo-setup (no Devin environment), upload-secrets (no secrets to upload).

docs: align CLI help, README, llms.txt, and packaging metadata with the shipped surface
refactor: extract push-delivery mechanics from run.go into push.go

- Set GIT_TERMINAL_PROMPT=0 on every git subprocess so a remote without a
  credential helper fails fast instead of blocking on a prompt
- Replace em dashes with hyphens in --help output and README per style rules
- Document -h/--help in the README flag table and add --spacing to llms.txt
- Align the nfpm package description with the canonical channel description
- Point Windows shells at winget in install.sh's unsupported-OS error
- Refresh stale channel states in PUBLISHING-SETUP.md (npm OIDC provenance
  shipped at 0.3.0, winget PRs merged, Chocolatey versions moderated)
- Delete PRE-RELEASE-REVIEW.md: its v0.1.0 gate is verified complete via
  classic branch protection and three releases have shipped
- Scope the non-interactive claim: GIT_TERMINAL_PROMPT=0 covers HTTPS
  credential prompts only; document that SSH/askpass prompts and hooks are
  unaffected in AGENTS.md, README, and llms.txt
- Replace the env-var assertion with a behavioral test: git ls-remote
  against a local 401 server must fail with "terminal prompts disabled"
- install.sh: cover all MSYS2 environments (UCRT64, CLANG64/32/ARM64)
- README: drop the stale "first-time Winget moderation" clause
- Skip when git is not on PATH, matching the package convention
- Neutralize global/system/env git config, proxies, and askpass so the
  only remaining credential path is the terminal prompt under test
@jishnuteegala
jishnuteegala merged commit ac7e025 into main Oct 10, 2026
10 checks passed
@jishnuteegala
jishnuteegala deleted the docs/quality-pass branch October 10, 2026 21:36
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