#!/bin/sh

# Parse the command line.
tarfile="html.tar.gz"

if test "$#" = "1" ; then
    tarfile=$1
fi

# Untar the html
tar zxmf $tarfile -C /project/projectdirs/visit/www/tests

cd /project/projectdirs/visit/www/tests

# Set the permissions
newDir=`ls -t | head -1`
chgrp -R visit $newDir
chmod -R g+rwX,o+rX $newDir
