From owner-freebsd-current@FreeBSD.ORG Thu Aug 17 18:05:32 2006 Return-Path: X-Original-To: freebsd-current@FreeBSD.org Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 014D716A4DD for ; Thu, 17 Aug 2006 18:05:32 +0000 (UTC) (envelope-from gad@FreeBSD.org) Received: from smtp6.server.rpi.edu (smtp6.server.rpi.edu [128.113.2.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8BA9043DD5 for ; Thu, 17 Aug 2006 18:04:53 +0000 (GMT) (envelope-from gad@FreeBSD.org) Received: from [128.113.24.47] (gilead.netel.rpi.edu [128.113.24.47]) by smtp6.server.rpi.edu (8.13.1/8.13.1) with ESMTP id k7HI4ksf027840; Thu, 17 Aug 2006 14:04:47 -0400 Mime-Version: 1.0 Message-Id: In-Reply-To: <44E3BFD8.6040901@elischer.org> References: <44DD4510.5070002@elischer.org> <20060816131824.67a8053b.algardo@sura.ru> <44E38F2C.8000207@elischer.org> <20060816213709.b53ded66.rnsanchez@gmail.com> <44E3BFD8.6040901@elischer.org> Date: Thu, 17 Aug 2006 14:04:45 -0400 To: Julian Elischer , Ricardo Nabinger Sanchez , des@des.no (Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= ) From: Garance A Drosehn Content-Type: text/plain; charset="us-ascii" ; format="flowed" X-CanItPRO-Stream: default X-RPI-SA-Score: undef - spam-scanning disabled X-Scanned-By: CanIt (www . canit . ca) Cc: freebsd-current@FreeBSD.org Subject: Re: suggested addition to 'date' X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Aug 2006 18:05:32 -0000 At 6:01 PM -0700 8/16/06, Julian Elischer wrote: >Ricardo Nabinger Sanchez wrote: >> >>My suggestion, if you happen to reconsider about having >>it only for your local usage, is to instead use a long >>option, like "--stamp" or "--timestamp". -s collides >>with GNU date set option, and people sometimes forget >>if they're in a BSD or GNU box (I do). >> >>I'd have sent this mail before, but I got shaky as I'm >>new here and because of the huge pressure for not >>committing such addition. > >I wouldn't call it huge pressure.. it was 2 for, >(now 3), 3 against and about 200 who couldn't care. After thinking about this awhile, I'd say that I'm mildly against it. The `date' command has never been a filter, and I don't see any reason that this feature needs to be in the `date' command as opposed to some other command. >It's just that the ney sayers always scream loudest. I'm certainly not screaming. But if we were to add this option somewhere, then des's suggestion of: It would make far more sense to add a date option to cat(1), which already has a line-numbering option. does seem very reasonable to me. `cat' already has several options which cause data to be filtered as it is copied. The only trick is that you also want to specify the format to use for the timestamp. So, just have the new parameter require a strftime() string: cat -D "%Y-%m%d-%H%M: " And maybe include a reference to the `cat' command in the man page for the `date' command, just so people realize that the option is available. -- Garance Alistair Drosehn = drosehn@rpi.edu Senior Systems Programmer or gad@FreeBSD.org Rensselaer Polytechnic Institute; Troy, NY; USA