Repository navigation
Cover the Exported GIT_WORK_TREE and GIT_DIR Drive Spellings in the Guard Self-Test - #2470
Conversation
…uard Self-Test The Git Bash drive cases covered every directory spelling but the leading `export NAME=value &&` form. Both exported variables now have a case, and each fails with the conversion removed. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 28 minutes. View limit detailsLimit details: You’ve used the included review currently available. Review configuration: ⚙️ Run configuration
📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
No unresolved review issues were identified.
Review effort: Lite
Findings: None
What changed in this PR
Adds self-test coverage for exported Git Bash GIT_WORK_TREE and GIT_DIR drive-path spellings.
Changes:
- Adds denial cases for both exported variable forms.
- Leaves guard behavior unchanged.
| File | Description |
|---|---|
host-setup/agent-safety/claude/gh-write-guard.py |
Adds two exported environment-variable self-test cases. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #2470 +/- ##
========================================
Coverage 58.47% 58.47%
========================================
Files 16 16
Lines 8062 8062
========================================
Hits 4714 4714
Misses 3348 3348
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
@coderabbitai review |
|
Summary
Copilot's overview on the promotion PR #2469 noted that the exported
GIT_WORK_TREE/GIT_DIRspelling had no self-test case. #2460 asks for one per spelling. This adds bothexport NAME=/c/... && git reset --hardforms to the Git Bash drive block. The guard code is unchanged, since_leading_export_dirsvalues already pass through_expand_dir.Verification
_msys_drive_pathreplaced by identity, both fail.local-strict-reviewraised no findings. It also showed that with_leading_export_dirsstubbed out, both cases allow, so it is the export parse that makes them deny. The same probe under WSL Linux matched.Refs #2460
🤖 Generated with Claude Code