#!/bin/sh if [ $# -eq 0 ]; then echo "usage: etcl filename" >&2 exit 1 fi echo '#!/bin/sh' >$1 echo '# the next line restarts using tclsh \' >>$1 echo 'exec tclsh "$0" "$@"' >>$1 echo >>$1 echo >>$1 chmod 755 $1 exec vi -c '4+' $1 .