544 Commits

Author SHA1 Message Date
andy.boot fc70f9ba30 Rename variable 2022-07-13 09:38:21 +01:00
andy.boot a00d1f0719 Fix: Allow -n to be used with -d
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.
2022-07-13 09:38:21 +01:00
andy.boot c4ea7815f8 Refactor: tweak utils function
Refactor simplify_dir_names to make it more readable
2022-07-01 12:04:31 +01:00
dependabot[bot] afc36a633f Bump regex from 1.5.4 to 1.5.5
Bumps [regex](https://github.com/rust-lang/regex) from 1.5.4 to 1.5.5.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.5.4...1.5.5)

---
updated-dependencies:
- dependency-name: regex
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-07 09:00:43 +01:00
unknown 7275b273d4 Fix archive/directory check in platform.rs 2022-05-02 12:11:22 +01:00
andy.boot a3e59f9c25 Update README.md 2022-03-05 22:02:09 +00:00
Adam Stephens 48bf656123 add aarch64 gnu and musl cross targets 2022-02-27 10:09:38 +00:00
andy.boot fabb27908d Increment version 2022-02-26 11:47:06 +00:00
andy.boot 52aeeebe1f Improve help text 2022-02-26 11:47:06 +00:00
andy.boot 1e27288ec2 Fix test: Remove unwanted mod
This line caused the test_symlinks files to be run twice.
2022-02-26 11:10:26 +00:00
andy.boot 9f4a5daee6 Update library: Clap
Required several changes to main.rs as v3 had breaking changes.
2022-02-26 11:10:26 +00:00
andy.boot 27f0a015ef Update cargo packages 2022-02-26 11:10:26 +00:00
andy.boot 20d89bef91 Neaten code 2022-02-26 09:58:47 +00:00
andy.boot 469e6d0a69 Fix: Bug: names may be shortened unnecessarily
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.
2022-02-26 09:58:47 +00:00
andy.boot 2d58609d54 Fix: Add assert for low terminal width
If terminal is not wide enought to print text, then print an error
message

https://github.com/bootandy/dust/issues/204
2022-01-02 22:41:02 +00:00
andy.boot 109a0b90d4 Update help text: number_of_lines
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
2022-01-02 22:41:02 +00:00
andy.boot ab67c1a50e Update help text: Add note for -c about watch
Issue was raised about using dust with watch. The solution is to use
watch --color dust or watch dust -c

https://github.com/bootandy/dust/issues/205
2022-01-02 22:41:02 +00:00
Sourajyoti Basak 6a34b52d15 docs(readme): add pacstall installation method 2021-12-21 10:07:28 +00:00
Gustavobb f708305190 Feature: Implement ISO output 2021-11-20 12:13:30 +00:00
andy.boot 2749f56b7a Tests: Fix test on mac (hack)
For some unknown reason mac takes offence to searching for
'test_dir_unicode'. 'test_dir_hidden' seems to work fine.

This isn't a proper fix as I've just hacked round the problem. Ideally
I'd need a mac user to do some investigation.
2021-11-20 12:05:48 +00:00
andy.boot d983175189 Cleanup: Vec -> &[]. Remove println. 2021-10-24 14:05:14 +01:00
andy.boot 4b3dc3988d Tests: Move test apparent size to exact_output
Because apparent_size uses the test files created in /tmp it needs to be
in the test_exact_output where those files are copied. Otherwise the files
may not be there when the test is run.
2021-10-24 14:05:14 +01:00
andy.boot fa4405b58b Cleanup: Remove unused comment
This was fixed a few commits ago
2021-10-24 14:05:14 +01:00
andy.boot abb08f8e1a Tests: Add tests for multi regex support 2021-10-24 14:05:14 +01:00
andy.boot 9f91d446c1 Feature/Bugfix: Allow multiple regexs to be used
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.
2021-10-24 14:05:14 +01:00
andy.boot 1b07c3c4f3 Update README.md
add note from https://github.com/bootandy/dust/issues/191
2021-10-24 09:33:02 +01:00
andy.boot e55b917c96 Add .deb files to release procedure 2021-10-11 18:33:27 +01:00
andy.boot 0301c7a058 Increment version
(skipped several due to build difficulties)
2021-09-19 13:50:10 +01:00
andy.boot bbed8d7478 Revert "Fix ci: Github actions: Publish step"
This reverts commit 5116c1c8a1.
2021-09-19 13:50:10 +01:00
andy.boot 17e7390e25 Increment version
new flags added -e -v -t
2021-09-19 11:40:21 +01:00
andy.boot 1cb731533b bugfix: Allow dust to work on low width terminal
Do not assume the min width is 80 (unless on windows).
2021-09-19 11:40:21 +01:00
andy.boot d6c2482150 Clap: use default_value on input
This avoids uses one less 'match' statement
2021-09-19 11:12:23 +01:00
andy.boot 9d2e6d2b36 Feature: Filter by invert_filter: reverse match
Mimic grep's -v option.

Allows dust to only match files that do not match the given filter
2021-09-19 11:12:23 +01:00
andy.boot 124c19b5c9 Feature: Adding file types filter & F flag changed
-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
2021-09-19 11:12:23 +01:00
Ethan Smith d8a334df3b Make the other parts of the workflow conditional 2021-09-06 08:54:27 +01:00
Ethan Smith c485e84145 Use single quotes? 2021-09-06 08:54:27 +01:00
Ethan Smith f51e9dd222 Conditionally build on musl and fix typo 2021-09-06 08:54:27 +01:00
Ethan Smith c25f7d342c Build Debian packages in CI 2021-09-06 08:54:27 +01:00
andy.boot ca0a93f222 Tests: Refactor
Move apparent size test to 'test_flags' file. We can no longer test the
exact output of this test as it changes too much on different filesystems

Move common code to shared initialization function in test_flags.rs
2021-08-06 11:07:48 +01:00
andy.boot 9cf260e42b Tests: Refactor: Improve exact output tests
Move more shared code into single function
2021-08-06 11:07:48 +01:00
andy.boot 87b1f50b39 Tests: Refactor: Neaten 2021-08-06 11:07:48 +01:00
andy.boot 3458c98bd0 Tests: Refactor: More code reuse 2021-08-06 11:07:48 +01:00
andy.boot 2ad420d370 Possible test fix: Some tests fail on some linux
An issue raised that the test output looked a lot like the mac output.
This change causes test to pass if output is either mac or linux style
2021-08-06 10:21:46 +01:00
andy.boot 2047f99c6d Update README.md 2021-08-06 10:11:10 +01:00
andy.boot 9bd2f9fc2a Update README.md 2021-08-06 10:01:10 +01:00
andy.boot 5116c1c8a1 Fix ci: Github actions: Publish step
The rules for github actions appear to have changed
2021-08-05 19:10:48 +01:00
andy.boot 07ffd04950 Increment version
This version includes fix for the -f flag
v0.6.2
2021-08-05 08:47:47 +01:00
andy.boot dfa574375b clippy: Fix clippy lints
New rustup adds more lints
2021-08-05 08:47:47 +01:00
andy.boot 9de2e7d723 bugfix: Fix crash when using '-f' 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
2021-07-29 08:54:32 +01:00
andy.boot 8fddb24165 Increment version v0.6.1 2021-07-19 14:09:21 +01:00