How can I run a csh script from a tcl script?
The csh script is indeed run for you, but by default its standard output becomes the result of the Tcl exec
command (and if it produced anything on standard error, that would become an error result of the exec
). To make the output and error appear on the terminal, you have to modify the exec
like this:
exec /bin/csh -c $synthesis >@stdout 2>@stderr
The >@
says “redirect standard output to the following channel” (stdout
in this case), and the 2>@
does the same for standard error.