From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Feb 23 13:50:11 2004 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 55DFC16A4CE for ; Mon, 23 Feb 2004 13:50:11 -0800 (PST) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 351BA43D1D for ; Mon, 23 Feb 2004 13:50:11 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) i1NLoAbv068486 for ; Mon, 23 Feb 2004 13:50:10 -0800 (PST) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.10/8.12.10/Submit) id i1NLoAuD068485; Mon, 23 Feb 2004 13:50:10 -0800 (PST) (envelope-from gnats) Date: Mon, 23 Feb 2004 13:50:10 -0800 (PST) Message-Id: <200402232150.i1NLoAuD068485@freefall.freebsd.org> To: freebsd-ports-bugs@FreeBSD.org From: Ulrich Spoerlein Subject: Re: ports/63222: [patch] Remove useless use of cat 5/5 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Ulrich Spoerlein List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Feb 2004 21:50:11 -0000 The following reply was made to PR ports/63222; it has been noted by GNATS. From: Ulrich Spoerlein To: Michael Nottebrock Cc: freebsd-gnats-submit@FreeBSD.org Subject: Re: ports/63222: [patch] Remove useless use of cat 5/5 Date: Mon, 23 Feb 2004 22:44:15 +0100 On Mon, 23.02.2004 at 21:19:25 +0100, Michael Nottebrock wrote: > I am not going to start another lengthy debate in this PR by asking you in > just what way "useless use of cat" sets a "bad" example. Instead I'll cut it > short: What you're trying to do to is enforce your (and possibly some other > people's as well) idea of good _style_. In other words, the decision of using > stdin or not is primarily a matter of _taste_. I don't want to force style on anyone. I thought that "useless use of cat" was considered a bad style all around. I can't find any discussion in the mail archives but was under the impression that it is generally not well accepted. There are also some occurences where just these cat|sed uses have been eliminated. See http://freebsd.rambler.ru/srch?old_q=useless+use+of+cat&words=%22useless+use+of+cat%22&where=7 > This isn't about bugs or bad examples, it's about bikeshedding. Everyone can > do a substitution with sed, and everyone can use redirections. Debating the > best way to do it serves no purpose. This PR and your other four do not > either. Please request to close them. Set the "good example" in your own > ports. I myself am using 'cat file | sed/awk/...' quite often on the _command_ line_, because I know the filename first, then I think about how to accomplish a given thing (Should I use awk or grep or sed?). Writing the command in the way the data gets processed is more intuitive. IMHO this point does not apply to scripts/makefiles, where you normally aren't writing the commands but you read (and try to understand) them. If everyone on FreeBSD is happy with cat|sed then just close the PRs and forget the whole incident. You might want to commit PR 63220 though, since the maintainer has approved the changes. Ulrich Spoerlein -- PGP Key ID: F0DB9F44 Get it while it's hot! PGP Fingerprint: F1CE D062 0CA9 ADE3 349B 2FE8 980A C6B5 F0DB 9F44 I abhor a system designed for the "user", if that word is a coded pejorative meaning "stupid and unsophisticated". -- Ken Thompson