From owner-freebsd-standards@FreeBSD.ORG Wed Mar 24 17:20:12 2004 Return-Path: Delivered-To: freebsd-standards@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1D7E116A4CE for ; Wed, 24 Mar 2004 17:20:12 -0800 (PST) Received: from smtp3.server.rpi.edu (smtp3.server.rpi.edu [128.113.2.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id BC4C243D3F for ; Wed, 24 Mar 2004 17:20:11 -0800 (PST) (envelope-from drosih@rpi.edu) Received: from [128.113.24.47] (gilead.netel.rpi.edu [128.113.24.47]) by smtp3.server.rpi.edu (8.12.8/8.12.8) with ESMTP id i2P1KBLP030540; Wed, 24 Mar 2004 20:20:11 -0500 Mime-Version: 1.0 X-Sender: drosih@mail.rpi.edu Message-Id: In-Reply-To: References: <1080165171.2232.910.camel@cube> Date: Wed, 24 Mar 2004 20:20:09 -0500 To: Albert Cahalan , freebsd-standards@freebsd.org From: Garance A Drosihn Content-Type: text/plain; charset="us-ascii" ; format="flowed" X-Scanned-By: CanIt (www . canit . ca) Subject: Re: PATCH for a more-POSIX `ps', and related adventures X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Mar 2004 01:20:12 -0000 At 7:43 PM -0500 3/24/04, Garance A Drosihn wrote: >At 4:52 PM -0500 3/24/04, Albert Cahalan wrote: > >> > I am not thrilled with that idea, but at the moment I can't >> > think of a better one. I *would* like to support matches of >> > both real and effective users. I guess we could add some >> > other option which would say "use the POSIX definitions of >> > -u and -U", but that doesn't exactly thrill me either. >> >>Why not? Tru64 uses the CMD_ENV environment variable to >>handle this. Linux does too, with PS_PERSONALITY taking >>priority. So, on either OS, you can do: > >I don't like keying a command's option-parsing behavior off of >environment variables. I can be talked into it if it would be >following some precedent in other OS's, but my initial-reaction >to this tactic (for any command) is to avoid it. Please note that >this isn't some multi-month project that I've been working on, I >have been looking at this for less than a week, and very little >of that week. I just thought I'd do some of the "easy stuff" >that would get our `ps' a little closer to SUSv3. > >So, given a little time you might be able talk me into using >environment vars to clean this up, but at the moment: ENOTIME... I should mention that I have been thinking of MAYBE creating some new command, say `psx', which would be much more SUSv3 compatible. It would be the same source code as `ps', and the behavior would key off of the name of the executable. Actually, maybe two new commands, `psbsd' and `psx'. In 5.x-stable we would have `ps' be exactly the same as `psbsd', and in 6.x-current we could have `ps' be exactly the same as `psx'. That way, scripts which HAD to work on both systems could pick the executable that they wanted. I haven't discussed that with anyone else yet, though. It's just something that came to mind when I was thinking about all these conflicting-options over the weekend. For all I know, everyone here would hate the idea... Give me another week to think about it, and I might even hate the idea! -- Garance Alistair Drosehn = gad@gilead.netel.rpi.edu Senior Systems Programmer or gad@freebsd.org Rensselaer Polytechnic Institute or drosih@rpi.edu