[PR #401] [MERGED] Fix -x option behavior #466

Closed
opened 2026-06-08 11:28:31 +03:00 by zhus · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bootandy/dust/pull/401
Author: @rindeal
Created: 5/27/2024
Status: Merged
Merged: 6/27/2024
Merged by: @bootandy

Base: masterHead: get_filesystem_devices


📝 Commits (4)

  • 4473ccf Fix -x option behavior
  • c44a9d6 streamline func APIs processing target_dirs
  • 845317c test_exact_output: refactor unreadable directory handling
  • 09b8de9 test_exact_output: simplify array handling

📊 Changes

5 files changed (+66 additions, -54 deletions)

View changed files

📝 src/dir_walker.rs (+1 -1)
📝 src/main.rs (+2 -2)
📝 src/platform.rs (+13 -12)
📝 src/utils.rs (+12 -12)
📝 tests/test_exact_output.rs (+38 -27)

📄 Description

This PR addresses an issue where target_dirs were being optimized out before being passed to the get_filesystem_devices() function. The changes in this PR ensure that target_dirs are passed directly to get_filesystem_devices(), and only then are they simplified.

Example of a command that currently doesn't work correctly:

dust -x $(findmnt -S tmpfs -o target -n)

It should show the usage of all tmpfs mounts, but it currently shows just the the root mountpoints like /run, since all the mountpoints nested under it are optimized out.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bootandy/dust/pull/401 **Author:** [@rindeal](https://github.com/rindeal) **Created:** 5/27/2024 **Status:** ✅ Merged **Merged:** 6/27/2024 **Merged by:** [@bootandy](https://github.com/bootandy) **Base:** `master` ← **Head:** `get_filesystem_devices` --- ### 📝 Commits (4) - [`4473ccf`](https://github.com/bootandy/dust/commit/4473ccf0080cda7dd4c8ea2da5755ea8e8cf8cd6) Fix -x option behavior - [`c44a9d6`](https://github.com/bootandy/dust/commit/c44a9d63f454486e33c826cd9ba8a4142a2a31ed) streamline func APIs processing target_dirs - [`845317c`](https://github.com/bootandy/dust/commit/845317c25e92ff5d8de8a65e204234f8c480140e) test_exact_output: refactor unreadable directory handling - [`09b8de9`](https://github.com/bootandy/dust/commit/09b8de9aaa235ed38e8f09adc52fe75a3964254b) test_exact_output: simplify array handling ### 📊 Changes **5 files changed** (+66 additions, -54 deletions) <details> <summary>View changed files</summary> 📝 `src/dir_walker.rs` (+1 -1) 📝 `src/main.rs` (+2 -2) 📝 `src/platform.rs` (+13 -12) 📝 `src/utils.rs` (+12 -12) 📝 `tests/test_exact_output.rs` (+38 -27) </details> ### 📄 Description This PR addresses an issue where `target_dirs` were being optimized out before being passed to the `get_filesystem_devices()` function. The changes in this PR ensure that `target_dirs` are passed directly to `get_filesystem_devices()`, and only then are they simplified. Example of a command that currently doesn't work correctly: ```sh dust -x $(findmnt -S tmpfs -o target -n) ``` It should show the usage of all tmpfs mounts, but it currently shows just the the root mountpoints like `/run`, since all the mountpoints nested under it are optimized out. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
zhus added the pull-request label 2026-06-08 11:28:31 +03:00
zhus closed this issue 2026-06-08 11:28:31 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: bootandy/archived-dust#466