Allow -n for number_of_lines to be used with -d 'max depth'
Remove depth specific functions, the job is now handled by the mainline
Add depth as a field onto the Node object.
The code calculating the width of a row to use vs the width of the
terminal wasn't quite right.
If we had 2 long filepaths one at the top of the dir tree and one at the
bottom the old code would shorten both equally. This doesn't make sense
as the one at the shallowest part of the tree would have used less
screen real estate and so should show a longer part of the filepath.
Remove note about 'height' and '-h being help' because it confused
people.
Add text to explain default height is terminal height - 10
https://github.com/bootandy/dust/issues/201
The -e and -v flags allow multiple values. Before values after the first
were ignored. This change allows the user to specify multiple regexs and
have them all applied.
-t = Show summary of types
-e = Filter by regex
allows you to specify a file type like -e "\.txt$"
Change behaviour of '-f' flag - it now counts only files. Before it
counted files & directories. This was needed for compatibility with
the new '-e' filter flag
The old code was subtly different in the way the root node worked. This
changed in the v0.6.0 version when dependencies were removed. The code
to handle file count was never updated
https://github.com/bootandy/dust/issues/162
Code changes:
Removed ignore & channel crates. Using a single reciever thread to build
a hashmap to prevend duplicate inodes being reported gave a severe
performance penalty
Using rayon crate with some hand crafted file traversal has improved
performance aprox 10X
Behaviour changes:
Removed parameter 'limit by filesystem' - don't think this is used, and
I only added it as it was easy to add with the ignore crate.
Sym links will now not appear in the output tree unless using '-s'
'apparent-size' flag
Change behaviour of multiple args so that it unifies them and
compares them under one tree instead of treating them
individually: https://github.com/bootandy/dust/issues/136
Add support for width flag
https://github.com/bootandy/dust/issues/126
Requested because some people may cat the output
All terminal height/width detection is now in the main file. One method
now has too many args for clippy, this complaint is valid and in the
future we should consider pulling these out into a separate object.
* remove unneeded identity .map()
* remove redunant field name in struct
* impl num_siblings for Node
* replace nested if w/ match in get_tree_chars
* remove unneeded field name in struct
* remove redundant println! & logic in display_node
* make get_children_from_node a Node method
* Revert "remove redundant println! & logic in display_node"
This reverts commit 40777025d5.
Change the depth flag so that it only changes the depth of displayed
subdirectories, not the depth of the directory size calculation (i.e.,
changing --depth does not change the displayed directory size, rather it
only changes how many levels of subdirectories are shown).
From feature request to respect the .gitignore file. Decided to bundle in
respect for hidden files into the same feature [otherwise if you obey
the .gitignore file you still endup showing the .git directory]
https://github.com/bootandy/dust/issues/92
Not 100% sure if this code is clean yet, may well be a better way to do
it
Also:
Added test directory with incredably long name as test case.
Update test_symlinks.py for mac runners. Mac test runners create files
with very long names, hence the tests fail periodically unless they look
for a truncated name with '..' at the end.
The enum variant `ansi_term::Colour::Red` (which uses the ANSI color code `31`)
is used instead of the code `196` to display the size of the largest file. This
means that the red color of the terminal theme is used which is probably
preferred by most users.