#!/bin/sh
#
# %W% %G%
#
# Script to uncompress and unarchive a repository or project archive,
# created with ot_archive.sh.
#
# Assumes that 'gzip' and 'tar' are in the current search path.
#
if [ $# != 1 ]; then
    echo 1>&2 "Usage: ot_unarchive <sourceFile>"
    exit 1
fi

src=$1

echo "Uncompressing and untarring archive $src ..."
echo "(working directory is `pwd`)"
if gzip -c -d $src | tar xf -; then :; else
    exit 1
fi

echo "Ready."
exit 0
