dua (-> Disk Usage Analyzer) is a tool to conveniently learn about the usage of disk space of a given directory. It's parallel by default and will max out your SSD, providing relevant information as fast as possible.
sh
curl -LSfs https://japaric.github.io/trust/install.sh | \
sh -s -- --git byron/dua-cli --crate dua
Via cargo
, which can be obtained using rustup
cargo install dua-cli
Via xbps
on your VoidLinux system.
xbps-install dua-cli
Via dnf
on your Fedora system.
sudo dnf install rust-dua-cli
```bash
dua
dua *
dua aggregate --help ```
Launch into interactive mode with the i
or interactive
subcommand. Get help on keyboard
shortcuts with ?
.
Use this mode to explore, and/or to delete files and directories to release disk space.
Please note that great care has been taken to prevent accidential deletions due to a multi-stage process, which makes this mode viable for exploration.
bash
dua i
dua interactive
Thanks to this PR, hard links are now not counted anymore.
The -l
flag will count hard links as it did before.
And of course, this has no noticable performance impact.
Thanks to this PR, the old apparent size can be displayed with the
-A
flag, and the much more useful 'size on disk' is now shown by default.
To my pleasant surprise, this does not seem to affect performance at all - everything stays speedy.
Binaries for Linux and MacOS are now available on GitHub Releases.
Depending on the terminal used, it might not have been obvious which panel was active. This might be confusing to new and current users. Now the color of the widget frame is changed to light gray, instead of remaining gray.
dua
will not follow symbolic links when deleting directories. Thank a ton, @vks!
Technical Notes: Handling symbolic links properly is impossible without usage of symlink_metadata()
.
100.0%
instead. Thanks, @vks, for pointing it out.A critical bug was discovered which would lead to deletion
of unwanted directories
as dua
would follow symbolic links during traversal during deletion.
Please note that symbolic links to files would be treated correctly, only removing the symbolic link.
This is now fixed.
That way, pressing shift + O
to open the currently selected file won't possibly spam the terminal
with messages caused by the program used to find the system program to open the file.
Fixes #14
A sub-command bringing up a terminal user interface to allow drilling into directories, and clearing them out, all using the keyboard exclusively.
That's that. We also use tui-react
, something that makes it much more pleasant to handle the
application and GUI state.
Simple CLI to list top-level directories similar to sn-sort, but faster and more tailored to getting an idea of where most space is used.
bash
make tests
make
Thanks to jwalk, all there was left to do is to write a command-line interface. As jwalk
matures, dua should benefit instantly.
tests/fixtures
which don't render correctly in interactive mode.
This can be due to graphemes not interpreted correctly. With Chinese characters for instance,
column sizes are not correctly computed, leading to certain columns not being shown.
In other cases, the terminal gets things wrong - I use alacritty, and with certain characaters it
performs worse than, say iTerm3.
See https://github.com/minimaxir/big-list-of-naughty-strings/blob/master/blns.txt for the source.u32::max_value() - 1
) entries.
u32
(I guess)petgraph
crate, which declares it as unsafe
to use u64 for instance.termion
termion
exlusively, and even though tui
supports multiple backends, we only support its termion backend. Reason: tui
is only used for parts of the program, and in all other parts termion
is used for coloring the output. Thus we wouldn't support changing to a different backend anyway unless everything is done with TUI, which is really not what it is made for.