From unknown Sat Aug 16 11:39:00 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#6186 <6186@debbugs.gnu.org> To: bug#6186 <6186@debbugs.gnu.org> Subject: Status: du in coreutils should add the -d flag as a shortcut to --max-depth Reply-To: bug#6186 <6186@debbugs.gnu.org> Date: Sat, 16 Aug 2025 18:39:00 +0000 retitle 6186 du in coreutils should add the -d flag as a shortcut to --max-= depth reassign 6186 coreutils submitter 6186 Jon Ringuette severity 6186 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Thu May 13 14:48:31 2010 Received: (at submit) by debbugs.gnu.org; 13 May 2010 18:48:31 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCdSQ-0003U7-Dl for submit@debbugs.gnu.org; Thu, 13 May 2010 14:48:31 -0400 Received: from dilbert.fhcrc.org ([140.107.152.15]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCdRQ-0003TK-CG for submit@debbugs.gnu.org; Thu, 13 May 2010 14:47:29 -0400 Received: from dilbert.fhcrc.org (localhost.localdomain [127.0.0.1]) by localhost (Postfix) with SMTP id 5F0477FE7E for ; Thu, 13 May 2010 11:47:23 -0700 (PDT) Received: from exchange.fhcrc.org (CHICO.FHCRC.ORG [140.107.42.161]) by dilbert.fhcrc.org (Postfix) with SMTP id 12B397FE7A for ; Thu, 13 May 2010 11:47:23 -0700 (PDT) Received: from kosh.pc.scharp.org ([140.107.164.65]) by exchange.fhcrc.org with Microsoft SMTPSVC(6.0.3790.4675); Thu, 13 May 2010 11:47:22 -0700 From: Jon Ringuette Content-Type: multipart/alternative; boundary=Apple-Mail-64--883500515 Subject: du in coreutils should add the -d flag as a shortcut to --max-depth Date: Thu, 13 May 2010 11:47:22 -0700 Message-Id: To: submit@debbugs.gnu.org Mime-Version: 1.0 (Apple Message framework v1078) X-Mailer: Apple Mail (2.1078) X-OriginalArrivalTime: 13 May 2010 18:47:22.0877 (UTC) FILETIME=[B940EAD0:01CAF2CC] X-PMX-Version: 5.5.9.388399, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2010.5.13.183615 X-FHCRC-SCANNED: Thu May 13 11:47:23 2010 X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 13 May 2010 14:48:28 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.3 (-) --Apple-Mail-64--883500515 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Package : coreutils Version : All Command : du Type : Feature Request Hello, In the FreeBSD world it is common to have a short argument of '-d' for = --max-depth. This greatly shortens a command one must type to when a = depth argument is used (which from my experience is often). For example currently to say get the size of all the home directories of = users one would use : du /home -h --max-depth=3D1 . It would make = life simpler and make going from FreeBSD systems to Linux systems easier = for people and scripts if the syntax : du /home -h -d 1 was also = supposed. Thank you, --=20 Jon Ringuette SCHARP/FHCRC 1100 Fairview ave. N LE-400 Office: Phone: 206.667.6378 Mobile: 206.659.5660 Fax: 206.667.4812 E-mail: jonr@scharp.org CONFIDENTIALITY NOTICE: This e-mail message and any attachments may be = confidential and privileged. If you are not intended to receive this message, please notify the sender and destroy the message. Thank you. --Apple-Mail-64--883500515 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii Package : coreutils
Version = : All
Command : du
Type : Feature = Request

Hello,

In the = FreeBSD world it is common to have a short argument of '-d' for = --max-depth.   This greatly shortens a command one must type to = when a depth argument is used (which from my experience is = often).

For example currently to say get the = size of all the home directories of users one would use :   =  du /home -h --max-depth=3D1   .   It would make life = simpler and make going from FreeBSD systems to Linux systems easier for = people and scripts if the syntax   : du /home -h -d 1 was also = supposed.

Thank = you,

-- 
SCHARP/FHCRC
1100 Fairview ave. N = LE-400
Office: Phone: 206.667.6378  Mobile: = 206.659.5660  Fax: 206.667.4812

CONFIDENTIALITY NOTICE: This = e-mail message and any attachments may be confidential and privileged. = If you are not intended to receive this
message, please notify the = sender and destroy the message. Thank you.

= --Apple-Mail-64--883500515-- From debbugs-submit-bounces@debbugs.gnu.org Thu May 13 15:19:57 2010 Received: (at 6186) by debbugs.gnu.org; 13 May 2010 19:19:57 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCdwq-0004kh-Ty for submit@debbugs.gnu.org; Thu, 13 May 2010 15:19:57 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCdwo-0004k4-MU for 6186@debbugs.gnu.org; Thu, 13 May 2010 15:19:55 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1OCdwj-0003M7-P4; Thu, 13 May 2010 15:19:49 -0400 To: 6186@debbugs.gnu.org Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth References: From: Glenn Morris X-Spook: Abbas Sundevil gamma diwn USDOJ Cohiba hackers Venezuela X-Ran: 0k,"oTeXFFyl:FZWb3"A#o[42H]`rbi9\<`PRKj09)kop.l)q)"6zaAbIRUtt!H,Mml$fN X-Hue: green X-Debbugs-No-Ack: yes X-Attribution: GM Date: Thu, 13 May 2010 15:19:49 -0400 In-Reply-To: (Jon Ringuette's message of "Thu\, 13 May 2010 11\:47\:22 -0700") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: 6186 Cc: Jon Ringuette X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) [ The following went to the help-debbugs list, I think because putting a space before the ':' in the pseudo-headers does not work. I am resending it so that it goes to the bug-coreutils list. Note that "Command" and "Type" are not recognized pseudo-headers. You don't need to worry about any of this, but if interested see http://debbugs.gnu.org/Reporting.html ] From: Jon Ringuette scharp.org> To: submit debbugs.gnu.org Package : coreutils Version : All Command : du Type : Feature Request Hello, In the FreeBSD world it is common to have a short argument of '-d' for --max-depth. This greatly shortens a command one must type to when a depth argument is used (which from my experience is often). For example currently to say get the size of all the home directories of users one would use : du /home -h --max-depth=1 . It would make life simpler and make going from FreeBSD systems to Linux systems easier for people and scripts if the syntax : du /home -h -d 1 was also supposed. Thank you, -- Jon Ringuette SCHARP/FHCRC 1100 Fairview ave. N LE-400 Office: Phone: 206.667.6378 Mobile: 206.659.5660 Fax: 206.667.4812 E-mail: jonr@scharp.org CONFIDENTIALITY NOTICE: This e-mail message and any attachments may be confidential and privileged. If you are not intended to receive this message, please notify the sender and destroy the message. Thank you. From debbugs-submit-bounces@debbugs.gnu.org Thu May 13 15:32:07 2010 Received: (at 6186) by debbugs.gnu.org; 13 May 2010 19:32:07 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCe8d-0005az-4z for submit@debbugs.gnu.org; Thu, 13 May 2010 15:32:07 -0400 Received: from mx1.redhat.com ([209.132.183.28]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCe8a-0005ad-RT for 6186@debbugs.gnu.org; Thu, 13 May 2010 15:32:06 -0400 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o4DJVx1I004913 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 13 May 2010 15:32:00 -0400 Received: from [10.3.241.101] (vpn-241-101.phx2.redhat.com [10.3.241.101]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o4DJVxHM026128; Thu, 13 May 2010 15:31:59 -0400 Message-ID: <4BEC53A0.8000700@redhat.com> Date: Thu, 13 May 2010 13:31:44 -0600 From: Eric Blake Organization: Red Hat User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100430 Fedora/3.0.4-3.fc13 Lightning/1.0b1 Mnenhy/0.8.2 Thunderbird/3.0.4 MIME-Version: 1.0 Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth References: In-Reply-To: X-Enigmail-Version: 1.0.1 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enigEDEF0E52CAE34BA4F757A49D" X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 X-Spam-Score: -9.4 (---------) X-Debbugs-Envelope-To: 6186 Cc: Jon Ringuette , 6186@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -9.3 (---------) This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigEDEF0E52CAE34BA4F757A49D Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 05/13/2010 01:19 PM, Jon Ringuette wrote: > For example currently to say get the size of all the home directories > of users one would use : du /home -h --max-depth=3D1 . It would make > life simpler and make going from FreeBSD systems to Linux systems > easier for people and scripts if the syntax : du /home -h -d 1 was > also supposed. Prior practice is always a good reason to support changes like this. It would be a very simple patch to du.c to convert --max-depth from long-option only to also having a short-option equivalent. Would you like to try your hand at it first? If not, I can probably get around to this in another day or two. --=20 Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org --------------enigEDEF0E52CAE34BA4F757A49D Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJL7FOmAAoJEKeha0olJ0NqoLMH/AnELKTBwUov8qvrDTzyJcLb vWK4OfyjOiA4ws1usNXdzagfrHcYiSlSlU1LBH42LGpaZsBUi9KBDG3McBzXH8gr oFvB1V82YNmYqZuKyzNzNGcyXPDNcgwYRUXqa7B3V4pjTORS/wxHKPgdHY9D/tRi 7ksuf2MNwqx2bRmhncELmZq2x2e6Vgpt+2MpHe3UGfobalf862XjdmclxZXfrI+U kkzjxoDOZbcF+RnriTm/565JTq5TLPByaJAOfLDAH1zK+ZcELVI1UmihgmB8P1dc QahhvOacqFA4BBT2I6xI3NW6auMH6zX7kX/2vGqCUO4cOOMGXpDnAnUVzwFzjqg= =veGv -----END PGP SIGNATURE----- --------------enigEDEF0E52CAE34BA4F757A49D-- From debbugs-submit-bounces@debbugs.gnu.org Thu May 13 15:47:17 2010 Received: (at 6186) by debbugs.gnu.org; 13 May 2010 19:47:17 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCeNI-0005hN-B7 for submit@debbugs.gnu.org; Thu, 13 May 2010 15:47:16 -0400 Received: from dilbert.fhcrc.org ([140.107.152.15]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCeJu-0005fQ-H2 for 6186@debbugs.gnu.org; Thu, 13 May 2010 15:43:47 -0400 Received: from dilbert.fhcrc.org (localhost.localdomain [127.0.0.1]) by localhost (Postfix) with SMTP id 958C77FE79; Thu, 13 May 2010 12:43:41 -0700 (PDT) Received: from exchange.fhcrc.org (CHICO.FHCRC.ORG [140.107.42.161]) by dilbert.fhcrc.org (Postfix) with SMTP id 09C7D7FE73; Thu, 13 May 2010 12:43:41 -0700 (PDT) Received: from kosh.pc.scharp.org ([140.107.164.65]) by exchange.fhcrc.org with Microsoft SMTPSVC(6.0.3790.4675); Thu, 13 May 2010 12:43:40 -0700 Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth Mime-Version: 1.0 (Apple Message framework v1078) Content-Type: multipart/alternative; boundary=Apple-Mail-65--880122544 From: Jon Ringuette In-Reply-To: <4BEC53A0.8000700@redhat.com> Date: Thu, 13 May 2010 12:43:40 -0700 Message-Id: <8ABB705B-839B-42CC-8BF2-BB1E1A0C2D61@scharp.org> References: <4BEC53A0.8000700@redhat.com> To: Eric Blake X-Mailer: Apple Mail (2.1078) X-OriginalArrivalTime: 13 May 2010 19:43:40.0877 (UTC) FILETIME=[96B2CFD0:01CAF2D4] X-PMX-Version: 5.5.9.388399, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2010.5.13.193615 X-FHCRC-SCANNED: Thu May 13 12:43:41 2010 X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 6186 X-Mailman-Approved-At: Thu, 13 May 2010 15:47:14 -0400 Cc: 6186@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.2 (--) --Apple-Mail-65--880122544 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Thank you for considering my request. I'll put a patch together for = submission. --=20 Jon Ringuette SCHARP/FHCRC 1100 Fairview ave. N LE-400 Office: Phone: 206.667.6378 Mobile: 206.659.5660 Fax: 206.667.4812 E-mail: jonr@scharp.org CONFIDENTIALITY NOTICE: This e-mail message and any attachments may be = confidential and privileged. If you are not intended to receive this message, please notify the sender and destroy the message. Thank you. On May 13, 2010, at 12:31 PM, Eric Blake wrote: > On 05/13/2010 01:19 PM, Jon Ringuette wrote: >> For example currently to say get the size of all the home directories >> of users one would use : du /home -h --max-depth=3D1 . It would make >> life simpler and make going from FreeBSD systems to Linux systems >> easier for people and scripts if the syntax : du /home -h -d 1 was >> also supposed. >=20 > Prior practice is always a good reason to support changes like this. = It > would be a very simple patch to du.c to convert --max-depth from > long-option only to also having a short-option equivalent. Would you > like to try your hand at it first? >=20 > If not, I can probably get around to this in another day or two. >=20 > --=20 > Eric Blake eblake@redhat.com +1-801-349-2682 > Libvirt virtualization library http://libvirt.org >=20 --Apple-Mail-65--880122544 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii Thank = you for considering my request.   I'll put a patch together for = submission.

-- 
SCHARP/FHCRC
1100 Fairview ave. N = LE-400
Office: Phone: 206.667.6378  Mobile: = 206.659.5660  Fax: 206.667.4812

CONFIDENTIALITY NOTICE: This = e-mail message and any attachments may be confidential and privileged. = If you are not intended to receive this
message, please notify the = sender and destroy the message. Thank you.


On May 13, = 2010, at 12:31 PM, Eric Blake wrote:

On = 05/13/2010 01:19 PM, Jon Ringuette wrote:
For= example currently to say get the size of all the home = directories
of users one would = use : du /home -h --max-depth=3D1 .  It would = make
life simpler and make = going from FreeBSD systems to Linux systems
easier for people and scripts if the syntax : du /home -h = -d 1 was
also = supposed.

Prior practice is always a good reason to = support changes like this.  It
would be a very simple patch to = du.c to convert --max-depth from
long-option only to also having a = short-option equivalent.  Would you
like to try your hand at it = first?

If not, I can probably get around to this in another day = or two.

--
Eric Blake   eblake@redhat.com =    +1-801-349-2682
Libvirt virtualization library http://libvirt.org


= --Apple-Mail-65--880122544-- From debbugs-submit-bounces@debbugs.gnu.org Thu May 13 19:39:05 2010 Received: (at 6186) by debbugs.gnu.org; 13 May 2010 23:39:05 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OChzc-0007AG-TB for submit@debbugs.gnu.org; Thu, 13 May 2010 19:39:05 -0400 Received: from dogbert.fhcrc.org ([140.107.89.15]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OChkZ-00074F-5i for 6186@debbugs.gnu.org; Thu, 13 May 2010 19:23:32 -0400 Received: from dogbert.fhcrc.org (localhost.localdomain [127.0.0.1]) by localhost (Postfix) with SMTP id BE30125805B; Thu, 13 May 2010 16:23:26 -0700 (PDT) Received: from exchange.fhcrc.org (ZEPPO.FHCRC.ORG [140.107.43.93]) by dogbert.fhcrc.org (Postfix) with SMTP id 3C6F0258067; Thu, 13 May 2010 16:23:26 -0700 (PDT) Received: from kosh.pc.scharp.org ([140.107.164.65]) by exchange.fhcrc.org with Microsoft SMTPSVC(6.0.3790.4675); Thu, 13 May 2010 16:23:26 -0700 Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth Mime-Version: 1.0 (Apple Message framework v1078) Content-Type: multipart/alternative; boundary=Apple-Mail-67--866937247 From: Jon Ringuette In-Reply-To: <4BEC53A0.8000700@redhat.com> Date: Thu, 13 May 2010 16:23:26 -0700 Message-Id: <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> References: <4BEC53A0.8000700@redhat.com> To: Eric Blake X-Mailer: Apple Mail (2.1078) X-OriginalArrivalTime: 13 May 2010 23:23:26.0087 (UTC) FILETIME=[49B23170:01CAF2F3] X-PMX-Version: 5.5.9.388399, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2010.5.13.231218 X-FHCRC-SCANNED: Thu May 13 16:23:26 2010 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 6186 X-Mailman-Approved-At: Thu, 13 May 2010 19:39:02 -0400 Cc: 6186@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.3 (--) --Apple-Mail-67--866937247 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii So here is my first whack at it. One thing to note is there was a = DU_DEBUG optional define that defined a -d flag to use for debugging. = It seemed like using -d would be more useful for everyone to use for = depth then for debug so I modified the slightly oddly thrown in debug = stuff to now work with --debug instead. Though when I actually define = DU_DEBUG so the #if DU_DEBUG is picked up and used it complains about = the function missing so I'm kind of curios if this has worked for = awhile. Anyways any feedback or recommendations would be greatly appreciated so = this has a better chance of making its way into the release. Thank you for your time on this matter! --=20 Jon Ringuette SCHARP/FHCRC On May 13, 2010, at 12:31 PM, Eric Blake wrote: > On 05/13/2010 01:19 PM, Jon Ringuette wrote: >> For example currently to say get the size of all the home directories >> of users one would use : du /home -h --max-depth=3D1 . It would make >> life simpler and make going from FreeBSD systems to Linux systems >> easier for people and scripts if the syntax : du /home -h -d 1 was >> also supposed. >=20 > Prior practice is always a good reason to support changes like this. = It > would be a very simple patch to du.c to convert --max-depth from > long-option only to also having a short-option equivalent. Would you > like to try your hand at it first? >=20 > If not, I can probably get around to this in another day or two. >=20 > --=20 > Eric Blake eblake@redhat.com +1-801-349-2682 > Libvirt virtualization library http://libvirt.org >=20 --Apple-Mail-67--866937247 Content-Type: multipart/mixed; boundary=Apple-Mail-68--866937246 --Apple-Mail-68--866937246 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii So = here is my first whack at it.  One thing to note is there was a = DU_DEBUG optional define that defined a -d flag to use for debugging. =  It seemed like using -d would be more useful for everyone to use = for depth then for debug so I modified the slightly oddly thrown in = debug stuff to now work with --debug instead.  Though when I = actually define DU_DEBUG so the #if DU_DEBUG is picked up and used it = complains about the function missing so I'm kind of curios if this has = worked for awhile.

Anyways any feedback or = recommendations would be greatly appreciated so this has a better chance = of making its way into the release.

Thank you = for your time on this matter!

Jon Ringuette
SCHARP/FHCRC


On May = 13, 2010, at 12:31 PM, Eric Blake wrote:

On = 05/13/2010 01:19 PM, Jon Ringuette wrote:
For= example currently to say get the size of all the home = directories
of users one would = use : du /home -h --max-depth=3D1 .  It would = make
life simpler and make = going from FreeBSD systems to Linux systems
easier for people and scripts if the syntax : du /home -h = -d 1 was
also = supposed.

Prior practice is always a good reason to = support changes like this.  It
would be a very simple patch to = du.c to convert --max-depth from
long-option only to also having a = short-option equivalent.  Would you
like to try your hand at it = first?

If not, I can probably get around to this in another day = or two.

--
Eric Blake   eblake@redhat.com =    +1-801-349-2682
Libvirt virtualization library http://libvirt.org


= --Apple-Mail-68--866937246-- --Apple-Mail-67--866937247-- From debbugs-submit-bounces@debbugs.gnu.org Fri May 14 04:06:24 2010 Received: (at 6186) by debbugs.gnu.org; 14 May 2010 08:06:24 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCpua-0002LL-5E for submit@debbugs.gnu.org; Fri, 14 May 2010 04:06:24 -0400 Received: from smtp1-g21.free.fr ([212.27.42.1]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OCpuX-0002LE-9r for 6186@debbugs.gnu.org; Fri, 14 May 2010 04:06:22 -0400 Received: from smtp1-g21.free.fr (localhost [127.0.0.1]) by smtp1-g21.free.fr (Postfix) with ESMTP id 5F76E940099 for <6186@debbugs.gnu.org>; Fri, 14 May 2010 10:06:14 +0200 (CEST) Received: from mx.meyering.net (mx.meyering.net [82.230.74.64]) by smtp1-g21.free.fr (Postfix) with ESMTP for <6186@debbugs.gnu.org>; Fri, 14 May 2010 10:06:13 +0200 (CEST) Received: by rho.meyering.net (Acme Bit-Twister, from userid 1000) id ABB10C20; Fri, 14 May 2010 10:06:12 +0200 (CEST) From: Jim Meyering To: Jon Ringuette Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth In-Reply-To: <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> (Jon Ringuette's message of "Thu, 13 May 2010 16:23:26 -0700") References: <4BEC53A0.8000700@redhat.com> <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> Date: Fri, 14 May 2010 10:06:12 +0200 Message-ID: <87632qrjpn.fsf@meyering.net> Lines: 15 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -3.1 (---) X-Debbugs-Envelope-To: 6186 Cc: 6186@debbugs.gnu.org, Eric Blake X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) Jon Ringuette wrote: > So here is my first whack at it. One thing to note is there was a DU_DEBUG optional define that defined a -d flag to use for debugging. It seemed like using -d would be more useful for everyone to use for depth then for debug so I modified the slightly oddly thrown in debug stuff to now work with --debug instead. Though when I actually define DU_DEBUG so the #if DU_DEBUG is picked up and used it complains about the function missing so I'm kind of curios if this has worked for awhile. Moving debug functionality to --debug is fine. Since it's compiled out and I haven't made an effort to enable it otherwise, it hasn't kept pace with other changes. No big deal. However, it was essential during the last round of big changes, so I'm not ready to remove it altogether just yet. > Anyways any feedback or recommendations would be greatly appreciated so this has a better chance of making its way into the release. > > Thank you for your time on this matter! Your patch did not reach the list. From debbugs-submit-bounces@debbugs.gnu.org Mon May 17 17:14:23 2010 Received: (at 6186) by debbugs.gnu.org; 17 May 2010 21:14:23 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OE7dn-0007N8-03 for submit@debbugs.gnu.org; Mon, 17 May 2010 17:14:23 -0400 Received: from dogbert.fhcrc.org ([140.107.89.15]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OE7dl-0007N0-7O for 6186@debbugs.gnu.org; Mon, 17 May 2010 17:14:22 -0400 Received: from dogbert.fhcrc.org (localhost.localdomain [127.0.0.1]) by localhost (Postfix) with SMTP id 58838B5D284; Mon, 17 May 2010 14:14:16 -0700 (PDT) Received: from exchange.fhcrc.org (ZEPPO.FHCRC.ORG [140.107.43.93]) by dogbert.fhcrc.org (Postfix) with SMTP id 1DDA6257E68; Mon, 17 May 2010 14:14:16 -0700 (PDT) Received: from kosh.pc.scharp.org ([140.107.164.65]) by exchange.fhcrc.org with Microsoft SMTPSVC(6.0.3790.4675); Mon, 17 May 2010 14:14:15 -0700 Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth Mime-Version: 1.0 (Apple Message framework v1078) Content-Type: multipart/alternative; boundary=Apple-Mail-74--529087542 From: Jon Ringuette In-Reply-To: <87632qrjpn.fsf@meyering.net> Date: Mon, 17 May 2010 14:14:15 -0700 Message-Id: <4F765D38-A809-4FCA-8CD1-20C9B1E9B799@scharp.org> References: <4BEC53A0.8000700@redhat.com> <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> <87632qrjpn.fsf@meyering.net> To: Jim Meyering X-Mailer: Apple Mail (2.1078) X-OriginalArrivalTime: 17 May 2010 21:14:15.0918 (UTC) FILETIME=[E7E340E0:01CAF605] X-PMX-Version: 5.5.9.388399, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2010.5.17.210614 X-FHCRC-SCANNED: Mon May 17 14:14:16 2010 X-Spam-Score: -1.1 (-) X-Debbugs-Envelope-To: 6186 Cc: 6186@debbugs.gnu.org, Eric Blake X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.2 (--) --Apple-Mail-74--529087542 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii I believe it shows up as an attachment on the = http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D6186 with my last email : = [du_add_d.patch (application/octet-stream, attachment)] I can also post the patch directly instead of as a file attachment if = that is easier. Just doing a normal #define DU_DEBUG 1 was giving me an error about = lower case function fts_cross_check not existing. Is there a better way = for me to test this to ensure my modification of the debug flag to = --debug did not negatively impact past work? thanks! -jon On May 14, 2010, at 1:06 AM, Jim Meyering wrote: > Jon Ringuette wrote: >> So here is my first whack at it. One thing to note is there was a = DU_DEBUG optional define that defined a -d flag to use for debugging. = It seemed like using -d would be more useful for everyone to use for = depth then for debug so I modified the slightly oddly thrown in debug = stuff to now work with --debug instead. Though when I actually define = DU_DEBUG so the #if DU_DEBUG is picked up and used it complains about = the function missing so I'm kind of curios if this has worked for = awhile. >=20 > Moving debug functionality to --debug is fine. > Since it's compiled out and I haven't made an effort > to enable it otherwise, it hasn't kept pace with other > changes. No big deal. However, it was essential during > the last round of big changes, so I'm not ready to remove > it altogether just yet. >=20 >> Anyways any feedback or recommendations would be greatly appreciated = so this has a better chance of making its way into the release. >>=20 >> Thank you for your time on this matter! >=20 > Your patch did not reach the list. --Apple-Mail-74--529087542 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii I = believe it shows up as an attachment on the http://debbug= s.gnu.org/cgi/bugreport.cgi?bug=3D6186 with my last email = : [du_add_d.patch = (application/octet-stream, attachment)]

I can = also post the patch directly instead of as a file attachment if that is = easier.

Just doing a normal = #define DU_DEBUG 1  was giving me an error about lower case = function fts_cross_check not existing.  Is there a better way = for me to test this to ensure my modification of the debug flag to = --debug did not negatively impact past = work?

thanks!

-jon
=



On May 14, 2010, = at 1:06 AM, Jim Meyering wrote:

Jon = Ringuette wrote:
So here is my first whack = at it.  One thing to note is there was a DU_DEBUG optional define = that defined a -d flag to use for debugging.  It seemed like using = -d would be more useful for everyone to use for depth then for debug so = I modified the slightly oddly thrown in debug stuff to now work with = --debug instead.  Though when I actually define DU_DEBUG so the #if = DU_DEBUG is picked up and used it complains about the function missing = so I'm kind of curios if this has worked for = awhile.

Moving debug functionality to --debug is = fine.
Since it's compiled out and I haven't made an effort
to = enable it otherwise, it hasn't kept pace with other
changes.  No = big deal.  However, it was essential during
the last round of = big changes, so I'm not ready to remove
it altogether just = yet.

Anyways any feedback or = recommendations would be greatly appreciated so this has a better chance = of making its way into the release.

Thank you for = your time on this matter!

Your patch did not reach = the list.

= --Apple-Mail-74--529087542-- From debbugs-submit-bounces@debbugs.gnu.org Tue May 18 02:56:23 2010 Received: (at 6186) by debbugs.gnu.org; 18 May 2010 06:56:23 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OEGj0-0003y5-Lw for submit@debbugs.gnu.org; Tue, 18 May 2010 02:56:23 -0400 Received: from smtp1-g21.free.fr ([212.27.42.1]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OEGiw-0003y0-R8 for 6186@debbugs.gnu.org; Tue, 18 May 2010 02:56:20 -0400 Received: from smtp1-g21.free.fr (localhost [127.0.0.1]) by smtp1-g21.free.fr (Postfix) with ESMTP id 0EFAB94014C for <6186@debbugs.gnu.org>; Tue, 18 May 2010 08:56:12 +0200 (CEST) Received: from mx.meyering.net (mx.meyering.net [82.230.74.64]) by smtp1-g21.free.fr (Postfix) with ESMTP for <6186@debbugs.gnu.org>; Tue, 18 May 2010 08:56:11 +0200 (CEST) Received: by rho.meyering.net (Acme Bit-Twister, from userid 1000) id BA6D7626; Tue, 18 May 2010 08:56:10 +0200 (CEST) From: Jim Meyering To: Jon Ringuette Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth In-Reply-To: <4F765D38-A809-4FCA-8CD1-20C9B1E9B799@scharp.org> (Jon Ringuette's message of "Mon, 17 May 2010 14:14:15 -0700") References: <4BEC53A0.8000700@redhat.com> <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> <87632qrjpn.fsf@meyering.net> <4F765D38-A809-4FCA-8CD1-20C9B1E9B799@scharp.org> Date: Tue, 18 May 2010 08:56:10 +0200 Message-ID: <874oi54s1h.fsf@meyering.net> Lines: 254 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -1.8 (-) X-Debbugs-Envelope-To: 6186 Cc: 6186@debbugs.gnu.org, Eric Blake X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) Jon Ringuette wrote: ... >> Your patch did not reach the list. > I believe it shows up as an attachment on the http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6186 with my last email : [du_add_d.patch (application/octet-stream, attachment)] I had not seen that. Besides, that is not the mailing list ;-) > I can also post the patch directly instead of as a file attachment if that is easier. > > Just doing a normal #define DU_DEBUG 1 was giving me an error about lower case function fts_cross_check not existing. Is there a better way for me to test this to ensure my modification of the debug flag to --debug did not negatively impact past work? I was going to request this: Please do post to the list. However, a few guidelines: - post git format-patch output, not diff -c output - please update NEWS with a sentence describing your change - also update doc/coreutils.texi (that's the primary documentation) - change/extend a test to exercise the new option (hmm... no test exercises --max-depth=N, so asking you to do this isn't really fair) If you're not familiar with git, a quick how-to is in readme files. Start with README-hacking to checkout the sources, then read the first few paragraphs of HACKING for instructions on setting up and using git. but I've decided to do it all for you, and in so doing discovered one part that has to be changed: we can't introduce the --debug option your patch adds, since that shares a prefix with --dereference-args. Currently, both --d and --de serve as abbreviations for that long-named option. If we were to add --debug, they would become ambiguous and make those uses stop working. Besides, --debug can't do anything unless gnulib's fts.c is compiled with debugging enabled. Eventually, or while debugging, I may add the three-hyphen ---debug option, but for now have simply commented that out. I've added a test for --max-depth=N, then wrote the commit log, NEWS, .texi and test changes to go with your code patch. ------------------------------- >From a1b74559f1b0dc60b866fa9c0220096fa4abffeb Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Tue, 18 May 2010 08:39:40 +0200 Subject: [PATCH 1/2] tests: exercise du's --max-depth option * tests/Makefile.am (TESTS): Add du/max-depth. * tests/du/max-depth: New file. --- tests/Makefile.am | 1 + tests/du/max-depth | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 0 deletions(-) create mode 100755 tests/du/max-depth diff --git a/tests/Makefile.am b/tests/Makefile.am index a732c63..c458574 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -350,6 +350,7 @@ TESTS = \ du/inaccessible-cwd \ du/long-from-unreadable \ du/long-sloop \ + du/max-depth \ du/no-deref \ du/no-x \ du/one-file-system \ diff --git a/tests/du/max-depth b/tests/du/max-depth new file mode 100755 index 0000000..4ddb6b7 --- /dev/null +++ b/tests/du/max-depth @@ -0,0 +1,31 @@ +#!/bin/sh +# exercise du's --max-depth=N option + +# Copyright (C) 2010 Free Software Foundation, Inc. + +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +. "${srcdir=.}/init.sh"; path_prepend_ ../src + +mkdir -p a/b/c/d/e || framework_failure_ +printf 'a/b/c\na/b\na\n' > exp || framework_failure_ + +du --max-depth=2 a > out 2>err || fail=1 + +# Remove the sizes. They vary between file systems. +cut -f2- out > k && mv k out +compare out exp || fail=1 +compare err /dev/null || fail=1 + +Exit $fail -- 1.7.1.250.g7d1e8 >From 1ccacf7a1b5b93f9e4c8ef562ceceab9726f8656 Mon Sep 17 00:00:00 2001 From: Jon Ringuette Date: Tue, 18 May 2010 08:26:11 +0200 Subject: [PATCH 2/2] 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. --- NEWS | 3 +++ doc/coreutils.texi | 2 ++ src/du.c | 15 +++++++-------- tests/du/max-depth | 7 +++++++ 4 files changed, 19 insertions(+), 8 deletions(-) diff --git a/NEWS b/NEWS index 5d7b81f..19436fe 100644 --- a/NEWS +++ b/NEWS @@ -4,6 +4,9 @@ GNU coreutils NEWS -*- outline -*- ** New features + du recognizes -d N as equivalent to --max-depth=N, for compatibility + with FreeBSD. + sort now accepts the --debug option, to highlight the part of the line significant in the sort, and warn about questionable options. diff --git a/doc/coreutils.texi b/doc/coreutils.texi index 77434e9..115e5fb 100644 --- a/doc/coreutils.texi +++ b/doc/coreutils.texi @@ -10427,7 +10427,9 @@ du invocation For each symbolic links encountered by @command{du}, consider the disk space used by the symbolic link. +@item -d @var{depth} @item --max-depth=@var{depth} +@opindex -d @var{depth} @opindex --max-depth=@var{depth} @cindex limiting output of @command{du} Show the total for each directory (and file if --all) that is at diff --git a/src/du.c b/src/du.c index 907ad79..5d83dc6 100644 --- a/src/du.c +++ b/src/du.c @@ -56,10 +56,8 @@ extern bool fts_debug; #if DU_DEBUG # define FTS_CROSS_CHECK(Fts) fts_cross_check (Fts) -# define DEBUG_OPT "d" #else # define FTS_CROSS_CHECK(Fts) -# define DEBUG_OPT #endif /* Initial size of the hash table. */ @@ -192,7 +190,7 @@ enum EXCLUDE_OPTION, FILES0_FROM_OPTION, HUMAN_SI_OPTION, - MAX_DEPTH_OPTION, + FTS_DEBUG, TIME_OPTION, TIME_STYLE_OPTION }; @@ -204,6 +202,7 @@ static struct option const long_options[] = {"block-size", required_argument, NULL, 'B'}, {"bytes", no_argument, NULL, 'b'}, {"count-links", no_argument, NULL, 'l'}, + /* {"-debug", no_argument, NULL, FTS_DEBUG}, */ {"dereference", no_argument, NULL, 'L'}, {"dereference-args", no_argument, NULL, 'D'}, {"exclude", required_argument, NULL, EXCLUDE_OPTION}, @@ -211,7 +210,7 @@ static struct option const long_options[] = {"files0-from", required_argument, NULL, FILES0_FROM_OPTION}, {"human-readable", no_argument, NULL, 'h'}, {"si", no_argument, NULL, HUMAN_SI_OPTION}, - {"max-depth", required_argument, NULL, MAX_DEPTH_OPTION}, + {"max-depth", required_argument, NULL, 'd'}, {"null", no_argument, NULL, '0'}, {"no-dereference", no_argument, NULL, 'P'}, {"one-file-system", no_argument, NULL, 'x'}, @@ -312,7 +311,7 @@ Mandatory arguments to long options are mandatory for short options too.\n\ -x, --one-file-system skip directories on different file systems\n\ -X, --exclude-from=FILE exclude files that match any pattern in FILE\n\ --exclude=PATTERN exclude files that match PATTERN\n\ - --max-depth=N print the total for a directory (or file, with --all)\n\ + -d, --max-depth=N print the total for a directory (or file, with --all)\n\ only if it is N or fewer levels below the command\n\ line argument; --max-depth=0 is the same as\n\ --summarize\n\ @@ -694,7 +693,7 @@ main (int argc, char **argv) for (;;) { int oi = -1; - int c = getopt_long (argc, argv, DEBUG_OPT "0abchHklmsxB:DLPSX:", + int c = getopt_long (argc, argv, "0abd:chHklmsxB:DLPSX:", long_options, &oi); if (c == -1) break; @@ -702,7 +701,7 @@ main (int argc, char **argv) switch (c) { #if DU_DEBUG - case 'd': + case FTS_DEBUG: fts_debug = true; break; #endif @@ -744,7 +743,7 @@ main (int argc, char **argv) output_block_size = 1024; break; - case MAX_DEPTH_OPTION: /* --max-depth=N */ + case 'd': /* --max-depth=N */ { unsigned long int tmp_ulong; if (xstrtoul (optarg, NULL, 0, &tmp_ulong, NULL) == LONGINT_OK diff --git a/tests/du/max-depth b/tests/du/max-depth index 4ddb6b7..ec22989 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 -- 1.7.1.250.g7d1e8 From debbugs-submit-bounces@debbugs.gnu.org Wed May 19 03:17:36 2010 Received: (at 6186-done) by debbugs.gnu.org; 19 May 2010 07:17:36 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OEdX6-00082P-8q for submit@debbugs.gnu.org; Wed, 19 May 2010 03:17:36 -0400 Received: from smtp1-g21.free.fr ([212.27.42.1]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OEdX3-00082J-Mb for 6186-done@debbugs.gnu.org; Wed, 19 May 2010 03:17:34 -0400 Received: from smtp1-g21.free.fr (localhost [127.0.0.1]) by smtp1-g21.free.fr (Postfix) with ESMTP id E737994018A for <6186-done@debbugs.gnu.org>; Wed, 19 May 2010 09:17:27 +0200 (CEST) Received: from mx.meyering.net (mx.meyering.net [82.230.74.64]) by smtp1-g21.free.fr (Postfix) with ESMTP for <6186-done@debbugs.gnu.org>; Wed, 19 May 2010 09:17:26 +0200 (CEST) Received: by rho.meyering.net (Acme Bit-Twister, from userid 1000) id D2786F2F; Wed, 19 May 2010 09:17:25 +0200 (CEST) From: Jim Meyering To: Jon Ringuette Subject: Re: bug#6186: du in coreutils should add the -d flag as a shortcut to --max-depth In-Reply-To: <874oi54s1h.fsf@meyering.net> (Jim Meyering's message of "Tue, 18 May 2010 08:56:10 +0200") References: <4BEC53A0.8000700@redhat.com> <7704E1BB-4CD3-40FB-A0ED-53B8489BA7F2@scharp.org> <87632qrjpn.fsf@meyering.net> <4F765D38-A809-4FCA-8CD1-20C9B1E9B799@scharp.org> <874oi54s1h.fsf@meyering.net> Date: Wed, 19 May 2010 09:17:25 +0200 Message-ID: <87ocgcs6m2.fsf_-_@meyering.net> Lines: 41 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -3.1 (---) X-Debbugs-Envelope-To: 6186-done Cc: 6186-done@debbugs.gnu.org, Eric Blake X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) Jim Meyering wrote: ... >>>From a1b74559f1b0dc60b866fa9c0220096fa4abffeb Mon Sep 17 00:00:00 2001 > From: Jim Meyering > Date: Tue, 18 May 2010 08:39:40 +0200 > Subject: [PATCH 1/2] tests: exercise du's --max-depth option > > * tests/Makefile.am (TESTS): Add du/max-depth. > * tests/du/max-depth: New file. ... >>>From 1ccacf7a1b5b93f9e4c8ef562ceceab9726f8656 Mon Sep 17 00:00:00 2001 > From: Jon Ringuette > Date: Tue, 18 May 2010 08:26:11 +0200 > Subject: [PATCH 2/2] 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. > --- > NEWS | 3 +++ > doc/coreutils.texi | 2 ++ > src/du.c | 15 +++++++-------- > tests/du/max-depth | 7 +++++++ > 4 files changed, 19 insertions(+), 8 deletions(-) > > diff --git a/NEWS b/NEWS > index 5d7b81f..19436fe 100644 > --- a/NEWS > +++ b/NEWS > @@ -4,6 +4,9 @@ GNU coreutils NEWS -*- outline -*- > > ** New features > > + du recognizes -d N as equivalent to --max-depth=N, for compatibility > + with FreeBSD. I've pushed those two change sets. From unknown Sat Aug 16 11:39:00 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 16 Jun 2010 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator