I am trying to run csh script from tcl script.
Below tcl script is called csh script
#!/usr/bin/tclsh set scripts_path /scratch/TCL_scripts/scripts_adders set synthesis /scratch/TCL_scripts/synthesis.csh set files [glob -directory $scripts_path *] split $files set files [lsort $files] set i 1 foreach script $files { puts "hello"
And the csh file (start) is below:
#!/bin/csh -f echo abcdefgh
When I execute only the csh file from my unix terminal, it works fine. When I invoke my Tcl script, it starts and really writes βhiβ and prints i, but the csh file is not executed because βabcdefghβ never appears in the terminal. I also tried other commands, and I always had the same problem: csh script never runs when I run it from Tcl script, although it works fine when I run it directly from the terminal.
(And my Tcl script ans csh script executes)
What should I do to run my csh script from my Tcl script?
Thank you very much
source share