Re: posix ps (was Re: Adding `pgrep' and `pkill' to /usr/bin)

From: Harti Brandt (brandt_at_fokus.fraunhofer.de)
Date: 03/28/04

  • Next message: John-Mark Gurney: "Re: Problem with usb in FreeBSD 4.8....help!!!"
    Date: Sun, 28 Mar 2004 18:47:18 +0200 (CEST)
    To: Stephen McKay <smckay@internode.on.net>
    
    

    On Sun, 28 Mar 2004, Stephen McKay wrote:

    SM>On Saturday, 27th March 2004, Garance A Drosihn wrote:
    SM>
    SM>>>$ PERSONALITY=freebsd ps -?
    SM>>
    SM>>Secondly, I personally am not fond of commands which COMPLETELY
    SM>>change their behavior based on environment variables. Different
    SM>>options, different formats, different rules.
    SM>
    SM>Unifying ps on all Unices (including FreeBSD) is an excellent idea, and
    SM>I fully support this.
    SM>
    SM>Using an environment variable (no matter what name is used) to switch
    SM>between radically different personalities is an appalling idea. No script
    SM>can depend on the output of ps thereafter.

    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.

    If you happen to write a script for BSD syntax just put LC_ALL=C
    PERSONALITY=BSD on top of it.

    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 beeing desirable.

    harti
    _______________________________________________
    freebsd-arch@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-arch
    To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org"


  • Next message: John-Mark Gurney: "Re: Problem with usb in FreeBSD 4.8....help!!!"

    Relevant Pages

    • Re: Is there a way to control the serivce control manager?
      ... > Our XPe device has two personalities. ... but a switch on the device sets the personality. ... > control manager will see the changes and do the right thing? ...
      (microsoft.public.windowsxp.embedded)
    • Is there a way to control the serivce control manager?
      ... Our XPe device has two personalities. ... start and run a different set of services depending on that switch. ...
      (microsoft.public.windowsxp.embedded)
    • Re: DeXter
      ... >> Huh? ... Nothing prevents you from doing that in Delphi 2005. ... >> easily develop in different personalities and switch between them. ...
      (borland.public.delphi.non-technical)
    • Re: posix ps (was Re: Adding `pgrep and `pkill to /usr/bin)
      ... I personally am not fond of commands which COMPLETELY ... >change their behavior based on environment variables. ... Using an environment variable to switch ... If multiple personalities is a desirable trait (and it's not clear that it ...
      (freebsd-arch)