For simple commands, you can “pipe” the output of one command to GGSCI’s input; for example:
$ echo "start EAIOU" | ggsci
will issue the “start EIAOU” command to GGSCI. GGSI’s messages will appear on the terminal.
For more than one command, you can either use the above with an OBEY command, or redirect the standard input to read from the file containing the commands:
$ echo "obey bunchacommands" | ggsci
$ ggsci < test.in > ./dirout/test.out
In the latter example, test.in has the Goldengate commands you want to run, and the output from GGSCI is redirected into the file test.out. You may also use the “>>” redirection to append the output to the specified file instead of replacing the contents of the file.