#!/bin/csh

if ( $1 == "") then
	echo usage: convertbeta3ToFinal pathname
	exit
endif

set DFILE=$1/data.dependency
set D1FILE=$1~/data.dependency
set BUIN=BuildUIsNow
set THISFILE=$0
set RS=${THISFILE:h}/replaceString

if ( -r $DFILE ) then
  if ( `fgrep $BUIN $DFILE` != "" ) then

	cp -r $1 $1~
	$RS $BUIN aCupOfCoffee < $D1FILE | $RS BUIN COFC >! $DFILE
	$RS $BUIN aCupOfCoffee < $1~/data.nib | $RS BUIN COFC >! $1/data.nib
    exit

  endif
endif

echo The file $1 seems not to use BuildUIsNow - not converted
