<html><body><div style="color:#000; background-color:#fff; font-family:garamond, new york, times, serif;font-size:12pt">Thanks, Marc.  I don't see why I'm having these problems either.  It worked fine under Windows 7.<br><br>steve@steve-Satellite-L555D ~/Desktop $ cat test.scm<br>(display (+ 1 2))<br>(exit)<br><br>steve@steve-Satellite-L555D ~/Desktop $ gsi test.scm<br>Gambit v4.6.7<br><br>> ,q<br>steve@steve-Satellite-L555D ~/Desktop $ gsi<br>Gambit v4.6.7<br><br>> (display (+ 1 2))<br>3> (exit)<br>steve@steve-Satellite-L555D ~/Desktop $ gsi :d- test.scm<br>Gambit v4.6.7<br><br>> ,q<br>steve@steve-Satellite-L555D ~/Desktop $ <br><br><div><span></span></div><div><br></div>  <div style="font-family: garamond, new york, times, serif; font-size: 12pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <font face="Arial" size="2"> <hr size="1">  <b><span
 style="font-weight:bold;">From:</span></b> Marc Feeley <feeley@iro.umontreal.ca><br> <b><span style="font-weight: bold;">To:</span></b> Steve Graham <jsgrahamus@yahoo.com> <br><b><span style="font-weight: bold;">Cc:</span></b> Gambit List <Gambit-list@iro.umontreal.ca> <br> <b><span style="font-weight: bold;">Sent:</span></b> Tuesday, March 19, 2013 9:45 AM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [gambit-list] Running gambit program<br> </font> </div> <br><br>On 2013-03-19, at 11:31 AM, Steve Graham <<a ymailto="mailto:jsgrahamus@yahoo.com" href="mailto:jsgrahamus@yahoo.com">jsgrahamus@yahoo.com</a>> wrote:<br><br>> Trying to figure out how to run a Gambit-C program from a Linux shell script.  <br>> <br>> These don't seem to work:<br>> gsi <filename><br>> gsi - <filename><br>> gsi -e <filename><br>> <br>> What does work?<br>> <br>> Thanks,
 Steve<br><br>I'm not sure what form of "shell script" you are trying to create.  The first form, i.e.<br><br>    gsi <filename><br><br>should work fine.  I don't see why it doesn't work for you.  It the problem is that you want the REPL I/O to go to stdin/stdout (for example if you want (pp ...) to got to stdout), then start gsi this way:<br><br>    gsi -:d- <filename><br><br>You can also write Scheme shell scripts on unix by using the following shebang line:<br><br>    #! /usr/bin/env gsi<br>    ...scheme code<br><br>Marc<br><br><br><br> </div> </div>  </div></body></html>