[net.micro.6809] OS9 pipes & a smarter shell

strick@gatech.UUCP (08/11/84)

... in response to James Jones' pipe query of july 7
   I was out of town and so this response is late ...
   I am interested in piping things from one process to another in other
ways than the shell's piping ability isn't capable of.  One thing that would
be nice is to have a 2-way path between two processes.  Another would be
catching the output of a shell command, as the UN*X shell must do in
things like  `` set dir1=`pwd` ''.  Or to send something into a command,
like lpr.
   All I know is that the shell that is about to spawn two piped processes
opens a path to "/pipe" in the "UPDATE." mode.  Then it uses the "I$DUP" to
open the other end of the pipe.  The two child processes inherit these
paths as they are created.  I think it might not be too hard to do this
from a basic09 (or other) program ... if you can use the I$DUP call.
I hope to have time to try some of this soon -- maybe it'll work.
  /* what doesn't work (I tried it): two processes just open paths to
"/pipe" and try to talk */
   One thing that must be different about pipeman than scfman is that when
one process has issued a read or write request to the scf device, others
requesting the device must wait until the first process has completed the
call (e.g.  the radio shack shell will not allow a process to print anything
to /term while the shell is waiting for input from it).  Pipeman cannot be
this way or you would have deadlock:   If you are doing " dir ! dump " and
dump issues a read to the pipe, you dont want dir to be blocked from sending
to it.  If we can't make pipes work like we want, we could make a scf mailbox
device driver to do this, except there would have to be two (one to write to
and one to read from) for this very reason.
 
   Has anyone written a smarter shell?  Positional parameters $1 $2 ...
don't seem to be too hard.  Wildcards $ and * would be a good bit harder.
And a 'for' would really make them useful.  If you can figure how to make
pipes, `command` would be possible.  I think the OS9 operating system
has what it needs to do these things, you just need to write the shell.
Memory will be a problem.  My lack of time is the worst problem.
   Anyone have a fairy godmother?
-- 
Henry Strickland
The Clouds Project, School of ICS, Georgia Tech, Atlanta GA 30332
CSNet:	Strick @ GATech		ARPA:	Strick.GATech @ CSNet-Relay
uucp:	...!{akgua,allegra,rlgvax,sb1,unmvax,ulysses,ut-sally}!gatech!strick