#!/bin/csh
set dirs = ( ? )
foreach i ( $dirs )
	cd $i
	set tfiles = `grep -l -i $1 *`
	if ( tfiles != '' ) then
	foreach j ($tfiles)
		echo $2 $j $3
		grep -i $1 $j
		$2 $j $3 
	end
	endif
	cd ..
end
exit 0
