[GH-ISSUE #11] Add flag to limit depth #4

Closed
opened 2026-06-08 11:25:15 +03:00 by zhus · 3 comments
Owner

Originally created by @bootandy on GitHub (Apr 19, 2018).
Original GitHub issue: https://github.com/bootandy/dust/issues/11

Originally assigned to: @bootandy on GitHub.

From Reddit:

Once thing I notice however is that you elected for limiting the number of lines rather then the depth of the tree. It would be a lot more useful to specify the depth of the tree like the way tree -L 3 works.

Not yet sure how this would work. Would "dust -d 2" show:

  1. All folders of depth 2 and below
  2. Show the biggest 15 but not show any subdirectories that were deeper than 2.

I imagine the (1) is correct

Originally created by @bootandy on GitHub (Apr 19, 2018). Original GitHub issue: https://github.com/bootandy/dust/issues/11 Originally assigned to: @bootandy on GitHub. From Reddit: Once thing I notice however is that you elected for limiting the number of lines rather then the depth of the tree. It would be a lot more useful to specify the depth of the tree like the way tree -L 3 works. Not yet sure how this would work. Would "dust -d 2" show: 1) All folders of depth 2 and below 2) Show the biggest 15 but not show any subdirectories that were deeper than 2. I imagine the (1) is correct
zhus closed this issue 2026-06-08 11:25:15 +03:00
Author
Owner
<!-- gh-comment-id:384946259 --> @bootandy commented on GitHub (Apr 27, 2018): https://github.com/bootandy/dust/commit/e6c777fb8bfe079b6a517abd4f8a80ff6611e251
Author
Owner

@ryuheechul commented on GitHub (Aug 14, 2021):

A small report

let me know if you want me to file another issue on this

dust -d 2 ~ works but not dust ~ -d 2 (silently fail?). My dust version is 0.6.2 and system is macOS M1.
On the contrast, du works either way. Thus I think people (at least someone like me) would expect this would work as well?

<!-- gh-comment-id:898873692 --> @ryuheechul commented on GitHub (Aug 14, 2021): ### A small report _let me know if you want me to file another issue on this_ `dust -d 2 ~` works but not `dust ~ -d 2` (silently fail?). My `dust` version is `0.6.2` and system is macOS M1. On the contrast, `du` works either way. Thus I think people (at least someone like me) would expect this would work as well?
Author
Owner

@bootandy commented on GitHub (Aug 17, 2021):

That will be an issue with the CLAP command arg parsing library, it might be possible to make it understand this or it might not. I'll look in to the clap usage instructions.

<!-- gh-comment-id:900096788 --> @bootandy commented on GitHub (Aug 17, 2021): That will be an issue with the CLAP command arg parsing library, it might be possible to make it understand this or it might not. I'll look in to the clap usage instructions.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: bootandy/archived-dust#4