From 2b8ecfa6f14db48fbc204b2fc4993de077289c2d Mon Sep 17 00:00:00 2001 From: Jon Ringuette Date: Tue, 18 May 2010 08:26:11 +0200 Subject: 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. --- tests/du/max-depth | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/du/max-depth') 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 -- cgit v1.2.3-54-g00ecf