From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fdb0e,cdca3dc8d6167cd4 X-Google-Attributes: gidfdb0e,public X-Google-Thread: f7344,a808e23c428d1184 X-Google-Attributes: gidf7344,public X-Google-Thread: 1164f8,cdca3dc8d6167cd4 X-Google-Attributes: gid1164f8,public X-Google-ArrivalTime: 2001-12-30 10:00:32 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news.kjsl.com!news.usenet2.org!citadel.in.taronga.com!not-for-mail From: peter@taronga.com (Peter da Silva) Newsgroups: comp.os.vms,alt.sys.pdp10,comp.sys.dec Subject: Re: historical evidence of what went wrong at DEC Date: 30 Dec 2001 17:48:05 GMT Organization: TSS Inc. Message-ID: References: <3roT7.207043$tf5.13617499@bin5.nnrp.aus1.giganews.com> <3C2E506A.152D03E0@fsi.net> <3C2E9C1C.64718678@fsi.net> NNTP-Posting-Host: citadel.in.taronga.com X-Trace: citadel.in.taronga.com 1009734485 6045 10.0.0.43 (30 Dec 2001 17:48:05 GMT) X-Complaints-To: usenet@taronga.com NNTP-Posting-Date: 30 Dec 2001 17:48:05 GMT X-Newsreader: trn 4.0-test72 (19 April 1999) Xref: archiver1.google.com comp.os.vms:57407 alt.sys.pdp10:8887 comp.sys.dec:10531 In article <3C2E9C1C.64718678@fsi.net>, David J. Dachtera wrote: >> >> >How do I get a shell to check/verify command line options and values (if >> >> >any) before it invokes the program? >> >> This doesn't make sense on UNIX, >> >Why not? (I suspect the answer may be "for legacy reasons".) >> Because UNIX has a completely different command line model than VMS. A UNIX >> command line is an array of strings, not a structured language construct. >Exactly my point. Other than placing itself between the kernel and the >programmer, teh shell does little or nothing you can't do yourself >(without the shell). Since that's exactly what it's supposed to do, and very little more, what *is* your point? DCL is a procedural programming language (albeit one with fairly primitive control structures) that sometimes runs external programs to perform commands. The UNIX shell is a nearly functional programming language that primarily controls the dataflow between external programs. This model turns out to be extraordinarily powerful, and allows you to build quite sophisticated programs out of simple components. It's nothing like DCL, and looking at features of DCL and trying to find them in the shell, or to criticise the shell for lacking them, is like complaining that your new minivan doesn't come equipped with a movie theatre and grocery store. >...but the original poster was comparing DCL to the scripting languages, >not the external utilities they may invoke. Important distinction. The original poster was talking about the ease of programming using the UNIX shell compared to using DCL. Since you can't do anything in the shell without external programs, it should be obvious to the most naive observer, at least at this late date in the discussion, that this distinction is purely an invention of yours and not something intended by the original poster. >> >> the DCL implementations on UNIX. You might as well ask how you chroot >> >> in VMS. >> >Simple: >> >$ DEFINE/EXEC/SYSTEM SYS$SYSTEM new_path_specification >> What happens if you access DUA0: directly at this point? >Yes. It's still MOUNTed and available. What's your point? Then you haven't performed the equivalent of a chroot. Chroot completely replaces the user-level view of the entire file and device namespace with the newly constructed subset. If I haven't mounted da0s2 in that namespace, it's not visible. >> >> >How do I get the shell to open/process an indexed file (i.e., do C-ISAM >> >> >the way DCL does RMS)? >> >> You call a utility program to do it. >> >Then, the external program is doing it, not the shell. >> Again, you can not make that distinction. >You not only can, you *MUST*! Must I? Why? >Try this: find a way to "break" the path to your utility programs >(clobber the PATH, rename /bin to /binbin, or whatever). Now can you "ls >*"? (No.) Can you "echo *"? (Yes.) So, yes, the concept of commands >which are "internal" to the shell vs. those which are not is vitally >important. But why stop there. Let's unmount all the devices, format all the file systems, and overwrite all the open shared libraries in memory! Hey, now you can't do anything! I completely fail to see why the behaviour of a system that you've deliberately broken has any bearing on the utility of the shell as a scripting environment on a working system. -- Rev. Peter da Silva, ULC. "Cave cuniculos lagana ferentes" "Be conservative in what you generate, and liberal in what you accept" -- Matthew 10:16 (l.trans)