[comp.os.minix] shar/sh incompatibilities

go@orstcs.cs.ORST.EDU (04/29/87)

This may not be a bug, but a "feature"...

I have tried unsuccessfully to create "shar" format archives that would
successfully "unshar."  The problem seems (with a rather skant glance
at sh) to be that sh tries to read in the entire shell script file into
internal structures before acting on it.  This causes the shell to choke
if the shar is longer than about (a guess -- haven't tried a binary
search yet) 15k.  After looking at a few of the sh.* files and finding
a comment density of 1:500 lines, I don't relish going in and changing
anything massively.  Besides, I'd probably just screw it up -- sh works
pretty d**m good as it is.

What I want to know is, has anyone written a "simple shell" ala some
of the MS-DOS "sh" routines for unsharing that they would like to
convert and post.  What is needed is a simple line-at-a-time shell
that knew about the redirection stuff but not about all the shell
variables and things (at least parameter substitution could be
ignored -- $VAR would be nice.)  I'd write one, but am overcommitted
as it is.  For Minix sh, simply knowing about "gres" would probably
be sufficient.  Any thoughts?

Gary Oliver
...!hp-pcd!hplabs!orstcs!go		(Until they pull my plug)

go@orstcs.cs.ORST.EDU (04/29/87)

In my previos posting of sh/shar incompatibility, I boogered my
signature.  It should read:

Gary Oliver
...!hplabs!hp-pcd!orstcs!go		(Until they pull my plug.)