From owner-freebsd-current@FreeBSD.ORG Sat Aug 12 20:08:18 2006 Return-Path: X-Original-To: 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 DAB1416A4DA for ; Sat, 12 Aug 2006 20:08:18 +0000 (UTC) (envelope-from prvs=julian=372565577@elischer.org) Received: from a50.ironport.com (a50.ironport.com [63.251.108.112]) by mx1.FreeBSD.org (Postfix) with ESMTP id A747E43D46 for ; Sat, 12 Aug 2006 20:08:18 +0000 (GMT) (envelope-from prvs=julian=372565577@elischer.org) Received: from unknown (HELO [192.168.2.3]) ([10.251.60.23]) by a50.ironport.com with ESMTP; 12 Aug 2006 13:08:18 -0700 Message-ID: <44DE3531.7040308@elischer.org> Date: Sat, 12 Aug 2006 13:08:17 -0700 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.13) Gecko/20060414 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Poul-Henning Kamp References: <3892.1155412387@critter.freebsd.dk> In-Reply-To: <3892.1155412387@critter.freebsd.dk> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Cc: Giorgos Keramidas , 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: Sat, 12 Aug 2006 20:08:18 -0000 Poul-Henning Kamp wrote: >In message <44DE2F5F.2010207@elischer.org>, Julian Elischer writes: > > >>Poul-Henning Kamp wrote: >> >> > > > >>You might say that the "logger" program would be overly bloated by >>having to include the whole of 'date'. >> >> > >Why would you need to include "the whole of 'date'" ? Have you >never heard of strftime(3) ? > > Of course but I think it makes more sense to add the ability for date to be able to put the date onto a stream than to write a whole new program for it, and date does extra work not included in strftime() that it would be nice to have. It could be said that adding a strftime() to 'cat' as an option is equally possible but that would be much more disruptive than adding filterring to date, as cat is not line oriented, To me it seems more natural to add the few extra lines to date because in my mind it is a natural usage of date and extending date to be able to be used as a filter doesn't hurt existing functionality. BTW. I agree that the last patch I gave was overly complicated and a much simpler one is possible.. Basically, Giorgos's suggested patch is pretty close to being right.