#!/bin/bash
# This script is used to prepare our tarball for release

#Remove this if you want to use it on your server
exit 0

TAG=$1

svn export --ignore-externals http://svn.savannah.gnu.org/svn/phpgroupware/core/tags/version_0_9_16-$TAG/ phpgroupware-0.9.16.$TAG

for mod in $(svn ls http://svn.savannah.gnu.org/svn/phpgroupware/modules/);
do
	 svn export http://svn.savannah.gnu.org/svn/phpgroupware/modules/$mod/tags/version_0_9_16-$TAG phpgroupware-0.9.16.$TAG/$mod
done

tar cf phpgroupware-0.9.16.$TAG.tar phpgroupware-0.9.16.$TAG
zip -r -9 phpgroupware-0.9.16.$TAG.zip phpgroupware-0.9.16.$TAG
bzip2 -k -9 phpgroupware-0.9.16.$TAG.tar
gzip -9 phpgroupware-0.9.16.$TAG.tar
