#!/bin/csh

cd cpac
set dirs = `ls -1`
set ndirs = `ls -1 | wc -l`

set c1 = 1

while ($c1 < $ndirs)
  cd $dirs[$c1]
  echo $dirs[$c1]
  sed -i -e s@archive\/xgtwo@archive\/xgtwo_5day@g *
@ c1 = $c1 + 1
  cd ..
end



