[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] Dumbass newbie questions. Sorry.
From: |
Shawn Rutledge |
Subject: |
Re: [Chicken-users] Dumbass newbie questions. Sorry. |
Date: |
Thu, 16 Apr 2009 15:58:30 -0700 |
2009/4/16 Neil Baylis <address@hidden>:
> Re processes/pipes, I had found those by looking in the manual, but am not
> yet sharp enough in scheme to understand them. It looks as though
> (process...) is what I need, but I'm not sure how to use it.
It will give you "ports" for stdin/stdout. e.g. (example to ssh to a
server, start a process and interact with it):
(let-values ([(recv-port send-port connppid) (process "ssh
address@hidden \"cd prj/dscm/services; ./x10-wish\"")])
...
then you can send and receive stuff, e.g.
(display "hey there" send-port)
and
(let ([response (read recv-port)])
... figure out what to do with it ...)
This chapter provides a starting overview of I/O in Scheme in general
(not Chicken-specific):
http://www.scheme.com/tspl3/io.html