File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -44,6 +44,7 @@ sudo cp target/release/struct /usr/local/bin/
4444
4545` ` ` bash
4646struct 3 # Show structure up to depth 3
47+ struct 0 # Show everything (infinite depth)
4748struct -g 2 # Git-tracked files only
4849struct -s 100 3 # Skip folders larger than 100MB
4950struct -i "*.log" 2 # Add custom ignore patterns
Original file line number Diff line number Diff line change @@ -170,7 +170,13 @@ fn main() {
170170 }
171171 }
172172
173- let depth = args. depth . unwrap_or ( 3 ) ;
173+ // Depth 0 means infinite, otherwise use provided depth or default to 3
174+ let depth = match args. depth {
175+ Some ( 0 ) => usize:: MAX , // Infinite depth
176+ Some ( d) => d,
177+ None => 3 , // Default depth
178+ } ;
179+
174180 let max_size_bytes = args. max_size_mb . map ( |mb| mb * 1024 * 1024 ) ;
175181
176182 // Load config patterns
You can’t perform that action at this time.
0 commit comments