From owner-freebsd-arch@FreeBSD.ORG Fri Nov 24 18:42:59 2006 Return-Path: X-Original-To: freebsd-arch@FreeBSD.ORG Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B1C1916A412 for ; Fri, 24 Nov 2006 18:42:59 +0000 (UTC) (envelope-from bakul@bitblocks.com) Received: from mail.bitblocks.com (bitblocks.com [209.204.185.216]) by mx1.FreeBSD.org (Postfix) with ESMTP id BD74C43D4C for ; Fri, 24 Nov 2006 18:42:16 +0000 (GMT) (envelope-from bakul@bitblocks.com) Received: from bitblocks.com (localhost.bitblocks.com [127.0.0.1]) by mail.bitblocks.com (Postfix) with ESMTP id 246945B1E for ; Fri, 24 Nov 2006 10:42:59 -0800 (PST) To: freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "Fri, 24 Nov 2006 18:40:13 +0100." <200611241740.kAOHeDHB072173@lurza.secnetix.de> Date: Fri, 24 Nov 2006 10:42:59 -0800 From: Bakul Shah Message-Id: <20061124184259.246945B1E@mail.bitblocks.com> Cc: Subject: Re: New option for ls(1), du(1), df(1) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Nov 2006 18:42:59 -0000 Oliver Fromme writes: ... > I've hacked a new option into those tools which uses > thousands separators for displaying the numbers. With > that option, the output looks like this (in US locale): > > Filesystem 1K-blocks Used Avail Capacity Mounted on > /dev/ad0s1a 1,012,974 62,418 869,520 7% / > /dev/ad0s1d 10,154,158 31,474 9,310,352 0% /var > /dev/ad0s1e 10,154,158 1,545,718 7,796,108 17% /usr > /dev/ad0s1f 128,009,212 1,358,600 116,409,876 1% /home > /dev/md0 297,326 20 273,520 0% /tmp ... Rather than add more code to quite a few programs I just use a separate program since this is useful in many places. $ df | hunit Filesystem 1K-blocks Used Avail Capacity Mounted on /dev/ad0s3a 99,183 66,198 25,051 73% / devfs 1 1 0 100% /dev /dev/ad0s3e 190,167 29,468 145,486 17% /var /dev/ad0s3f 61,147,922 54,629,382 1,626,708 97% /usr Granted, columns don't line up right but that too belongs in a separate program. > It is also worth noting that probably many more tools > might benefit from that feature. "netstat -i" and > "ipfw show" come to mind immediately. Which is why a separate program is nicer.