summaryrefslogtreecommitdiffstats
path: root/src/aggregate.rs
AgeCommit message (Collapse)Author
2024-01-14Traverse children vs parent & fix parent node size after refreshPiotr Wach
2024-01-07clippyPiotr Wach
2024-01-07Clean-up init functionPiotr Wach
2024-01-07Move ByteFormat out of WalkOptionsPiotr Wach
2023-12-26Keep consistent language/punctuation/case throughout the app.Piotr Wach
2023-05-05Simplify GUI refreshes by using a throttleSebastian Thiel
2023-05-05generalize the throttle implementation to allow usagein UISebastian Thiel
2023-02-22traverse: don't recurse on cross-device filesystemsThomas Orozco
Like it says in the title. Right now, if you pass `-x`, dua doesn't count files on other devices, but it still enumerates them. However, a good reason to use `-x` is if you have network mounts that are slow, so this fixes that.
2022-12-13thanks clippySebastian Thiel
2022-09-19refactorSebastian Thiel
2022-09-18refactor: colored path printing; fix size column formatSergey A
2022-09-01dependencies: switch from colored to owo-colorsSergey A
owo-colors is well-maintained, zero-allocation, zero-dependencies crate for terminal colors. Also it works on any type that implements Display trait, not just on strings.
2022-05-12fix: broken or non-existing root path will still print the valid results. (#124)Sebastian Thiel
Previously it would fail completely without printing anything.
2022-03-19Improve aggregate progress reportingThomas Hurst
Previously, aggregate mode progress reports were handled by an infinitely-looping thread carrying a 64-bit atomic of the current count, which it would print periodically. This resulted in #99 - breaking on platforms without 64-bit atomics, for which a feature was added to disable it. It also implied a race condition, where the "Enumerating ..." message could be printed after results had been gathered but before dua exited. Additionally, part of the status message could be left on the display if the first line of a report was too short to cover it. This commit should resolve these: * The 64-bit atomic counter is replaced with an 8-bit AtomicBool * All printing is controlled from the main thread * The first line is cleared prior to printing a report The only notable drawback I see with this approach is that progress reporting can sometimes be delayed, since the display is only evaluated for update during periods the aggregation loop makes progress. The practical difference appears relatively minor. Since this should resolve #99, the aggregate-scan-progress feature is removed.
2022-01-09fix: build on platforms without 64-bit atomicscinerea0
2021-08-19Format correctlyBen Armstead
2021-08-19Remove unnecessary lineBen Armstead
2021-08-05Add aggregate-scan-progress feature to help with #99Sebastian Thiel
2021-07-25upgrade open to v2Sebastian Thiel
2021-05-30Fix terrible bug causing an unnecessary wait in front of each invocationSebastian Thiel
2021-05-30Only fetch metadata for files for a speedupSebastian Thiel
2021-05-29Mildly optimize progress performance…Sebastian Thiel
…maybe there is a lot of error in the measurements, but it's a bit faster with different settings for atomics.
2021-05-29Only display progress on if stderr is a ttySebastian Thiel
2021-05-29Add simple progress to indicate something is happening on long `dua` runsSebastian Thiel
2021-03-23thanks clippySebastian Thiel
2020-07-27refactorSebastian Thiel
2020-07-27src, aggregate: fix colors for aggregate modeMaxim Zhukov
Use Cyan for folders in aggregate mode Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com>
2020-07-22update to colored 2.0Sebastian Thiel
2020-07-07Fix color handling (causing the text to disappear); fix tty detectionSebastian Thiel
Crossterm works differently from termion, I might say: more correct!
2020-07-06Replace termion::color with coloredSebastian Thiel
2020-07-06termcolor spends 1200 lines on handlings buffers, and it's not liking plain ↵Sebastian Thiel
io::Write Which means it doesn't like what's currently there. So let's go back to what can actually work: colored.
2020-07-06for a moment I thought 'colored' could be used, but…Sebastian Thiel
…it's really allocation heavy. Something simpler might be it, what about termcolor?
2020-07-02Use 'anyhow' instead of 'failure' to simplify code and reduce bloatSebastian Thiel
2020-07-02Use u128 for byte sizesThomas Hurst
Per issue #58, u64 is insufficient for use with very large sparse files. Enormous file sizes are also a common filesystem error trope, either from disk corruption or software bugs, and they're also conceivable with virtual filesystems. Handle this as gracefully as can be reasonably expected using 128-bit integers, which should be sufficient for most uses.
2020-05-04Add '-x' flag to not cross filesystemsSebastian Thiel
Fixes #3
2020-03-29cleanup 'quick-hack' done in 2.3.9 - much better nowSebastian Thiel
2020-03-27Truly don't follow symlinks unless they are the only top-level path.v2.3.9Sebastian Thiel
This is a brute-force hack which won't show them at all, there certainly is better ways if we would know if we expanded paths ourselves or not.
2020-03-26Considerably speed up dua interactive by allowing to use all (logical) coresSebastian Thiel
2020-03-24Update to filesize v0.2Thomas Hurst
2020-03-16jwalk 0.5 has landed - now we don't follow symlinks during traversal!Sebastian Thiel
2020-03-15Revert "Upgrade to jwalk 0.5; stop following symlinks during traversal"Sebastian Thiel
This reverts commit 4990fa4202f2b687ee2476efe0a406fdfe23fd96. Performance regression - it only uses a single thread for most of the iteration.
2020-03-15Upgrade to jwalk 0.5; stop following symlinks during traversalv2.3.4Sebastian Thiel
2020-02-22Rename 'count-links' to more descriptive 'count-hard-links'Sebastian Thiel
2020-02-22cargo fmtSebastian Thiel
2020-02-22Add hardlink tracking, and an option to disable itThomas Hurst
2020-02-22Add support for real/apparent sizeThomas Hurst
2019-06-16error formatting suggestionsJack O'Connor
We can avoid the `(s)` by inspecting the number. And using spaces instead of tabs makes the output more consistent in a terminal, no longer depending on the length of the preceding filename.
2019-06-04Support for changing the percentage displaySebastian Thiel
2019-06-04Properly fix byte column width handlingSebastian Thiel
2019-06-03bytes formatting for interactive + footerSebastian Thiel