Skip to content

Commit 0f620ba

Browse files
chaliyclaude
andauthored
feat(builtins): add grep -L, --exclude-dir, -s, -Z flags (#385)
## Summary - Add `-L`/`--files-without-match` flag: print filenames that have zero matches (inverse of `-l`) - Closes #380 - Add `--exclude-dir=GLOB` flag: skip entire directories during recursive grep - Closes #381 - Add `-s`/`--no-messages` flag: suppress error messages about nonexistent/unreadable files - Closes #382 - Add `-Z`/`--null` flag: print `\0` after filenames instead of `:` or `\n` (for `-l`/`-L` output and filename prefixes) - Closes #383 ## Test plan - [x] Unit tests for each flag (positive and negative cases) - [x] Spec tests for each flag in `grep.test.sh` - [x] `cargo fmt --check` passes - [x] `cargo clippy --all-targets --all-features -- -D warnings` passes - [x] `cargo test --all-features -p bashkit --lib` passes (1126 tests) - [x] `cargo test --all-features -p bashkit --test spec_tests -- grep` passes (82 spec tests) Co-authored-by: Claude <noreply@anthropic.com>
1 parent e201bf4 commit 0f620ba

File tree

2 files changed

+417
-22
lines changed

2 files changed

+417
-22
lines changed

0 commit comments

Comments
 (0)