diff options
author | Jon Ringuette <jonr@scharp.org> | 2010-05-18 08:26:11 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2010-05-19 07:28:16 +0200 |
commit | 2b8ecfa6f14db48fbc204b2fc4993de077289c2d (patch) | |
tree | 8a4b21f3e6de2d934934f20848e83d86387518ff /tests/du/max-depth | |
parent | 1be4f180f5395b9ef89ab9166e33ba9a54cfba8b (diff) | |
download | coreutils-2b8ecfa6f14db48fbc204b2fc4993de077289c2d.tar.xz |
du: recognize -d N as equivalent to --max-depth=N
* NEWS (New features): Mention it.
* src/du.c (DEBUG_OPT): Remove. Use long-named ---debug instead.
Commented out.
(MAX_DEPTH_OPTION): Remove. Use 'd' instead.
(main): Insert literal "d:"; remove DEBUG_OPT.
* doc/coreutils.texi (du invocation): Add -d to indices.
* tests/du/max-depth: Exercise -d, too.
Diffstat (limited to 'tests/du/max-depth')
-rwxr-xr-x | tests/du/max-depth | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/du/max-depth b/tests/du/max-depth index 4ddb6b7c9..ec22989c7 100755 --- a/tests/du/max-depth +++ b/tests/du/max-depth @@ -28,4 +28,11 @@ cut -f2- out > k && mv k out compare out exp || fail=1 compare err /dev/null || fail=1 +# Repeat, but use -d 1. +printf 'a/b\na\n' > exp || framework_failure_ +du -d 1 a > out 2>err || fail=1 +cut -f2- out > k && mv k out +compare out exp || fail=1 +compare err /dev/null || fail=1 + Exit $fail |