bglenden@mandrill.cv.nrao.edu (Brian Glendenning) (09/03/90)
All this reminds me of questions I've been meaning to ask: 1) Are there any versions of sh that don't understand # comments any more? 2) How common are sh's that don't understand shell functions? I'm particularly interested in the answer for machines that scientists are apt to buy and use (so that old PDP-11 in your closet doesn't count!) Brian -- Brian Glendenning - National Radio Astronomy Observatory bglenden@nrao.edu bglenden@nrao.bitnet (804) 296-0286
meissner@osf.org (Michael Meissner) (09/03/90)
In article <BGLENDEN.90Sep2172441@mandrill.cv.nrao.edu> bglenden@mandrill.cv.nrao.edu (Brian Glendenning) writes: | All this reminds me of questions I've been meaning to ask: | | 1) Are there any versions of sh that don't understand # comments any | more? It depends on when the last time you installed the system. If it was 1979 or such, then your shell probably doesn't understand # comments (I don't remember whether it was in the v7 shell, or not). But seriously, there are probably people running ancient systems out there that are stuck because their vendor went belly up years ago (of course you could probably buy a 386 running UNIX nowadays for a fraction of the original cost, but if you don't have the $5-10K at the present time, it doesn't matter). | 2) How common are sh's that don't understand shell functions? Anything that is BSD based without adding from System V. For example, the Ultrix DECstation that I'm posting from has the musty BSD shell as /bin/sh and the System V.2 shell with shell functions as /bin/sh5. Another problem with the BSD shell Ultrix uses, is that test (aka '[') is a separate command that you have to fork/exec to get to -- I suspect echo is too..... | I'm particularly interested in the answer for machines that scientists | are apt to buy and use (so that old PDP-11 in your closet doesn't | count!) You could always recomend bash and/or ksh. -- 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?
guy@auspex.auspex.com (Guy Harris) (09/04/90)
>It depends on when the last time you installed the system. If it was >1979 or such, then your shell probably doesn't understand # comments >(I don't remember whether it was in the v7 shell, or not). "#" comments weren't in the V7 shell. They are the 4.2BSD shell, and later BSD shells, and I think they were in the 4.1BSD shell as well; Berkeley added "#" comments to their otherwise V7-based shell.
jmm@eci386.uucp (John Macdonald) (09/04/90)
In article <4011@auspex.auspex.com> guy@auspex.auspex.com (Guy Harris) writes: |>It depends on when the last time you installed the system. If it was |>1979 or such, then your shell probably doesn't understand # comments |>(I don't remember whether it was in the v7 shell, or not). | |"#" comments weren't in the V7 shell. They are the 4.2BSD shell, and |later BSD shells, and I think they were in the 4.1BSD shell as well; |Berkeley added "#" comments to their otherwise V7-based shell. SCO (or Microsoft) supported "#" comments in System III, I don't recall whether it did in V7. -- Algol 60 was an improvment on most | John Macdonald of its successors - C.A.R. Hoare | jmm@eci386