#! /bin/csh -f
foreach i ($*)
	echo otv, autoseg, compress $i
	otv - <$i | otvplist >di.temp1
	if ($status == 0) then
		mv di.temp1 $i
		../autosplit -w -a <$i >../../AUTOSEG/$i
		compress $i
		mv $i.Z ..
		echo "  - OK"
	else
		echo "  - failed"
	endif
rm -f di.temp1
end
