Commit 8b739d9
authored
feat(builtins): add tree command (#581)
## Summary
- Add `tree` builtin for directory tree visualization
- Supports `-a` (hidden files), `-d` (dirs only), `-L N` (depth limit),
`-I pattern` (exclude)
- Unicode box-drawing characters, file/directory count summary
- 10 unit tests covering all options and edge cases
## Test plan
- [x] Unit tests for basic tree, hidden files, dirs-only, depth limit,
exclude pattern
- [x] Error cases: nonexistent dir, invalid depth, invalid option, empty
dir
- [x] `cargo clippy --all-targets --all-features -- -D warnings` passes
- [x] Full test suite passes (1621 tests)
Closes #5381 parent 3a10575 commit 8b739d9
3 files changed
+396
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
| |||
120 | 121 | | |
121 | 122 | | |
122 | 123 | | |
| 124 | + | |
123 | 125 | | |
124 | 126 | | |
125 | 127 | | |
| |||
0 commit comments