#!/bin/tcsh foreach i (`ls *.core`) set name=`echo $i | cut -d"." -f1` cp $i $name.dump end