🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.next.programmer
Article #179

Re: launching shell commands

#179
From: MKK2
Date: Wed, 22 Jul 1992 14:33
16 lines
1085 bytes
I've answered my own question.  (John Immordino at NeXT answered it too, and
it didn't cost me $225---yet 8-) 8-)

At first, I had given up on the Examples, but then I remembered that they
might use vfork instead of fork. Sure enough, a DL search on vfork() turned
up Subprocess.m, which does just what I needed.

It's in Examples/Subprocess.  You send it a shell command, and it vfork()'s,
execs the command in a /bin/sh, sets up a DPSAddFD(), and then sends a
message containing stdout each time appears.

It seems like a pretty nice solution.  If someone has added a lot of
functionality to Subprocess, it'd be a good candidate to the archives.

Thanks to everyone who emailed me suggestions.  Thanks again nets, just
for being there.
Technical Details
Message-ID: <92204.103326MKK2@psuvm.psu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!psuvax1!psuvm!mkk2
References: <92203.164622MKK2@psuvm.psu.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!psuvax1!psuvm!mkk2
Organization: Penn State University
Date: Wed, 22 Jul 1992 10:33:26 EDT
From: <MKK2@psuvm.psu.edu>
Message-ID: <92204.103326MKK2@psuvm.psu.edu>
Newsgroups: comp.sys.next.programmer
Subject: Re: launching shell commands
References:  <92203.164622MKK2@psuvm.psu.edu>
Lines: 16