On Thu, Jan 25, 2018 at 02:49:02PM -0800, Dennis Ruffer wrote:
> Say I want to do something like this: 
> 
> s" cd .. ; pwd" system /home/druffer
> 
> How do I get the output of pwd back into gforth?

You would use OPEN-PIPE instead of SYSTEM, but I don't have an example.

> I see infile-execute, but I don’t see an examples for me to try.

INFILE-EXECUTE is for making any file temporarily the standard input
(so that KEY reads from this file).  But for your problem, you need to
get the output of pwd into gforth.  A pipe does that.

> Is that the right path, or is there another?

You could use the C interface to call chdir(), getcwd(), and then
somehow chdir() back.

- anton

Reply via email to