#!/bin/sh
#
# BundleToI3dm is a shell script that converts a NeXT bundle into
# an i3dm bundle
#
#
# Use: BundleToI3dm <name> to convert <name>.bundle into <name>.i3dm
#
#

if [ $# != 1 ]; then
	echo "$0 <name> to convert <name>.bundle into <name>.i3dm"
	exit 1
fi

if [ ! -d $1.bundle ]; then
	echo "$1.bundle not found"
	exit 1
fi

if [ ! -d $1.i3dm ]; then
	mkdir $1.i3dm
fi

cp -rp $1.bundle/* $1.i3dm/
/bin/rm -f $1.i3dm/Module.a
/bin/mv $1.i3dm/$1 $1.i3dm/Module.a




