untermud/DOC/
untermud/DOC/U/
untermud/DOC/U/U-examples/
untermud/DOC/internals/
untermud/DOC/wizard/
untermud/MISC/
untermud/MISC/dbchk/
untermud/RWHO/
untermud/RWHO/rwhod/
#! /bin/sh

if [ ! $# = 1 ]; then
 echo 
 echo Builds an UnterMUD hash database installation from the minimal database,
 echo DB/minimal_db.oif, at the specified directory path.
 echo 
 echo usage: $0 directory_path
 echo 
 exit 1
fi

echo Building database...
declare -i y=0
while [ $y -lt 11 ]; do
  mkdir -p $1/hashdb/$y
  y=$y+1
done
./loaddb -hsv -i DB/minimal_db.oif -f $1/hashdb

echo Building HELP...
mkdir $1/HELP
cp HELP/* $1/HELP

echo Building NEWS...
mkdir $1/NEWS
echo Welcome to TestMud > $1/NEWS/welcome.txt
echo Connected to TestMud > $1/NEWS/connect.txt

echo Creating configuration...
echo _mudconfig chdir \"$1\" > $1/config
echo _mudconfig log \"mud.log\" >> $1/config
echo _mudconfig name \"TestMUD\" >> $1/config
echo _dbconfig hashpath \"hashdb\" >> $1/config
echo _netconfig playport 6565 >> $1/config
echo _netconfig servport 6566 >> $1/config
cp DB/startup $1
echo Player port is 6565