#!/bin/tcsh if ( $# != 2 ) then echo "This script requires two arguments:" echo " NAMD input file" echo " NAMD log file" exit -1 endif setenv CONFFILE $1 setenv LOGFILE $2 if ( ! -f $CONFFILE) then echo "NAMD input file $CONFFILE does not exist!" exit -1 endif if ( -f $LOGFILE) then echo "NAMD input file $LOGFILE already exists!" exit -1 endif echo "Starting NAMD..." echo "" /work2/tbss/jcphill/bin/`uname -s`/namd2 $CONFFILE >& $LOGFILE && \ echo "NAMD job completed! Output written to $LOGFILE" || \ echo "NAMD job failed! Output written to $LOGFILE" & echo "" echo "NAMD is running in the background, to monitor progress use this command:" echo "" echo " tail -f $LOGFILE" echo "" echo "You will need to press Control-C to exit the tail command." echo ""