Skip to content

fix: make SFD-387 allowlist probe man-independent - #60

Merged
jaruesink merged 1 commit into
mainfrom
meg/sfd387-man-independent
Sep 28, 2026
Merged

jaruesink merged 1 commit into
mainfrom
meg/sfd387-man-independent

Conversation

@jaruesink

Copy link
Copy Markdown
Contributor

Summary

  • Replace git <subcommand> --help with built-in -h usage probing so the read-only Git allowlist test does not depend on a platform man viewer.
  • Accept the expected usage exit (129) only when Git emits its usage text; unknown or misspelled commands still fail the guard.
  • Addresses the remaining AC1 portability fix in SFD-387.

Verification

  • man absent in the execution environment.
  • Focused scripts/lib/git-state.test.ts: 29 passed, 0 failed.
  • Full suite with local resource bounds (bun test --timeout=15000 --max-concurrency=4): 542 passed, 0 failed.
  • bun run lint: 0 errors (existing warnings only).
  • bun run typecheck: passed.
  • bun run format:check: passed.

@coderabbitai

coderabbitai Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: lambda-curry/anvil/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Essentials

Run ID: 30f456a4-f0d1-4161-add6-af0d53a4715a

📥 Commits

Reviewing files that changed from the base of the PR and between eb327d8 and a9bee25.

📒 Files selected for processing (1)
  • scripts/lib/git-state.test.ts

Included review availability: This review used your included allowance. 0 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 1 review per hour.


📝 Summary

Summary by CodeRabbit

  • Tests
    • Improved coverage of Git command help checks by accepting Git’s standard usage output with either supported exit status.

Walkthrough

The allowlist spelling test now probes applicable Git subcommands with -h. It checks combined output for Git usage text and accepts exit status 0 or 129 when that text is present.

Changes

Git help probe test

Layer / File(s) Summary
Help probe validation
scripts/lib/git-state.test.ts
The test uses -h, checks stdout and stderr for Git usage text, and accepts exit status 0 or 129 when that text appears.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to a9bee

The -h portability change preserves the allowlist spelling guard: invalid Git commands still fail the test. No actionable mergeability risk remains.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the portability fix and matches the main change: removing dependence on the platform man viewer for the SFD-387 allowlist probe.
Description check ✅ Passed The description includes a clear summary and detailed verification results. It omits the template’s Review checklist and does not use checklist boxes in Verification, but the main required information…
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

@jaruesink
jaruesink merged commit c304f8d into main Sep 28, 2026
3 checks passed
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