The closing code tag should be [/code]
Are you sure /bin/sh points to tcsh? Try using #!/bin/tcsh ( presuming tcsh is in bin
) Some shells like BASH ( I don't know about tcsh ) will allow/force slightly different syntax/comands when called as /bin/sh, in BASH this make BASH act 'posixly', is that a real word?