From owner-freebsd-arch@FreeBSD.ORG Sun Mar 28 16:42:12 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8DBE016A4CE; Sun, 28 Mar 2004 16:42:12 -0800 (PST) Received: from smtp3.adl2.internode.on.net (smtp3.adl2.internode.on.net [203.16.214.203]) by mx1.FreeBSD.org (Postfix) with ESMTP id EA56843D53; Sun, 28 Mar 2004 16:42:11 -0800 (PST) (envelope-from smckay@internode.on.net) Received: from dungeon.home (ppp190-27.lns1.bne1.internode.on.net [150.101.190.27])i2T0g3UK038756; Mon, 29 Mar 2004 10:12:03 +0930 (CST) Received: from dungeon.home (localhost [127.0.0.1]) by dungeon.home (8.12.8p2/8.11.6) with ESMTP id i2T0g2sv003657; Mon, 29 Mar 2004 10:42:02 +1000 (EST) (envelope-from mckay) Message-Id: <200403290042.i2T0g2sv003657@dungeon.home> To: Harti Brandt References: <20040325070120.GA67497@VARK.homeunix.com> <1a9c01c41359$b3da45e0$7890a8c0@dyndns.org> <200403280808.i2S88aJ7016011@dungeon.home> <20040328184244.I10175@beagle.fokus.fraunhofer.de> In-Reply-To: <20040328184244.I10175@beagle.fokus.fraunhofer.de> from Harti Brandt at "Sun, 28 Mar 2004 18:47:18 +0200" Date: Mon, 29 Mar 2004 10:42:02 +1000 From: Stephen McKay cc: "Jacques A. Vidrine" cc: arch@freebsd.org cc: Albert Cahalan cc: Garance A Drosihn cc: Stephen McKay Subject: Re: posix ps (was Re: Adding `pgrep' and `pkill' to /usr/bin) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Mar 2004 00:42:12 -0000 On Sunday, 28th March 2004, Harti Brandt wrote: >Well, that is just like LANG or LC_ALL. You cannot depend on parsing >utility output until you set LC_ALL=C, yet I have still to see a script >that does this. Yes, that is a significant deficiency of the internationalisation scheme. That doesn't mean we should copy it though. >If you happen to write a script for BSD syntax just put LC_ALL=C >PERSONALITY=BSD on top of it. Hopefully in the near future there will be a universally accepted default for ps options. Are you seriously suggesting that every script forevermore will have to put PERSONALITY=STANDARD (or similar) in front of a two character command name just to defeat this misfeature? >SM>If multiple personalities is a desirable trait (and it's not clear that it >SM>is) then command line switches and aliases are the correct mechanisms to >SM>use. > >That would require to add that switch to all utility calls in a script >that have multiple personalities. Thats far from being desirable. I don't understand. I was suggesting that if end users want different flavours of output they can select them with command line switches and aliases (if this is an option at all). This is as opposed to allowing users to select the default via an environment variable, which would negatively impact the use of ps in scripts. I can't see why scripts would want to use anything but the standard options. You only want to parse one format. Stephen.