🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.unix.shell
Article #1110

Re: bourne shell query

#1110
From: Michael Meissner
Date: Sun, 09 Sep 1990 21:42
38 lines
2172 bytes
In article <1990Sep7.193010.26787@dg-rtp.dg.com>
goudreau@dg-rtp.dg.com (Bob Goudreau) writes:

| In article <MEISSNER.90Sep6122432@osf.osf.org>, meissner@osf.org
| (Michael Meissner) writes:
	...
| > The standard way of dealing with this is:
| > 
| > if [ x"$1" = x"$2" ]; then
| > 	echo "Yeas!"
| > else
| > 	echo "No-way!"
| > fi
| 
| Why is even the "x" method necessary?  My system's Bourne shell
| (a port of V.3.2's sh) doesn't have any problem handling '=' or
| '-t' in the example Scott Yelich describes above.  Is this something
| AT&T fixed in the last couple of years?

It depends on whether you are trying to write maximally portable shell
scripts.  V7-based systems required this, because test was just
another command, and not handled by the shell.

BSD can't include the system V.2 shell (or anything else) because it
would mean that current BSD users would have to get a System V.2
license (which I don't think is offered anymore).  A System V.3
license is on the order of $60,000 for commercial sites, and V.4 is
rumored to be $100,000 (I know there are provisions for lower
university prices, but I don't have any data on them).  Also, the
'recent' AT&T licenses have had things various people have objected to
in the past (and to be fair there are people who can't sign the latest
BSD licenses, and I'm sure there are people who have problems with OSF
licenses).
--
Michael Meissner	email: meissner@osf.org		phone: 617-621-8861
Open Software Foundation, 11 Cambridge Center, Cambridge, MA, 02142

Do apple growers tell their kids money doesn't grow on bushes?
Technical Details
Message-ID: <MEISSNER.90Sep9174217@osf.osf.org>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!husc6!paperboy!meissner
References: <75@iconsys> <925@hls0.hls.oz> <MEISSNER.90Sep6122432@osf.osf.org> <1990Sep7.193010.26787@dg-rtp.dg.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!husc6!paperboy!meissner
From: meissner@osf.org (Michael Meissner)
Newsgroups: comp.unix.shell
Subject: Re: bourne shell query
Message-ID: <MEISSNER.90Sep9174217@osf.osf.org>
Date: 9 Sep 90 21:42:17 GMT
References: <75@iconsys> <925@hls0.hls.oz> <MEISSNER.90Sep6122432@osf.osf.org>
 <1990Sep7.193010.26787@dg-rtp.dg.com>
Sender: news@OSF.ORG
Organization: Open Software Foundation
Lines: 38
In-reply-to: goudreau@dg-rtp.dg.com's message of 7 Sep 90 19:30:10 GMT