[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Scraping the REPL?

From: Hefferon, James S.
Subject: Re: [Chicken-users] Scraping the REPL?
Date: Sat, 23 Jan 2016 17:51:28 +0000

Thank you for the "script" suggestion.  I apologize but I don't understand it.  

I'm looking for a way to automatically capture an interactive session, and drop 
it to a file, without cutting and pasting from a terminal or an editor.   When 
I use 
LaTeX to compile the book, I'd like that as part of the compilation it runs 
Chicken's csi and captures the session, so that session can be 
brought into the document.  (My past experience with cutting and pasting is 
that as 
the document changes the code samples get out of sync.  In addition, I'd like 
if a person gets the doc off my github account and they compile the doc then 
know their setup matches their doc.)

That is, I'd like to feed this to csi, and then grab the transcript.  

#;1> (+ 5 1)
#;2> (define (f x)
    (+ x 1))
#;3> (f 5)

I can get LaTeX to run programs, for example to call "csi -script foo.scm > 
foo.out".  But
I'm not sure if it is possible to grab the REPL without an Expect-type 

I understand "script" it will give me a single output, and not show the REPL at 
Am I missing the point (probably)?  

Thank you,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]