[gambit-list] How pipe from shell to gsc ('s repl)?
Adam
adam.mlmb at gmail.com
Thu Jul 14 00:08:41 EDT 2016
Ah, great!
Also the separation you mentioned is nice, that the REPL indeed is intended
to operate in a separate "controlling channel". It's interesting that
different platforms even have IO API:s for that, I had no idea.
So for what I was looking for, that I missed was this section in the
manual, was:
-
The REPL interaction channel will be standard input and standard output.
And the way to figure out how to use it is..
gsc [-:runtimeoption,…]
And "-" is a "debugging" option, documented by
The ‘d’ option sets various debugging options. The letter ‘d’ is followed
by a sequence of letters indicating suboptions.
so hence "-:d-", so:
$ *echo '(display "Hello world\n"),q' | gsc -:d-*
Gambit v4.8.0
> Hello world
>
$
Great!
Totally unimportantly, could I enable REPL echoing of the input commands,
or turn off REPL output altogether, from the command line?
So
$ *echo '(display "Hello world\n"),q' | gsc -:d- [somemorearg]*
Gambit v4.8.0
> (display "Hello world\n")
Hello world
> ,q
$
and
$ *echo '(display "Hello world\n"),q' | gsc -:d- - [somemorearg]*
Hello world
$
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.iro.umontreal.ca/pipermail/gambit-list/attachments/20160714/ea5b9548/attachment.htm>
More information about the Gambit-list
mailing list