can seem to get this to work:
******
#!/bin/sh
exec tclsh "$0" "$@"
set dir [file dirname [info script]]
puts $dir
set pwd [exec pwd]
puts $pwd
********
ofcourse the script works fine if I use tclsh scriptname.tcl and have removed the exe tclsh.. line, but I'm trying to understand how to use this function.
all help appreciated!!