#!/bin/bash export LC_ALL=C temp=$(mktemp -d) svn_base_uri="http://svn.openchrome.org/svn/trunk" svn_module="openchrome" tarball_prefix="xf86-video-${svn_module}" destination="root@cvs.magellan-linux.de:/var/www/htdocs/magellan/magellan-dev/sources/${tarball_prefix}/" echo -n "building latest tarball for ${tarball_prefix}... " cd ${temp} svn checkout ${svn_base_uri} ${svn_module} latest_revision=$(svn info ${svn_module} | grep Rev: | sed 's:.*Rev\:\ \(.*\):\1:') latest_version="0.2.904_svn${latest_revision}" mv ${temp}/${svn_module} ${tarball_prefix}-${latest_version} find ./${tarball_prefix}-${latest_version} -name .svn | xargs rm -r find ./${tarball_prefix}-${latest_version} -name .svnignore | xargs rm tar cvjf ${tarball_prefix}-${latest_version}.tar.bz2 ./${tarball_prefix}-${latest_version} scp ${tarball_prefix}-${latest_version}.tar.bz2 ${destination} if [[ -d ${temp} ]] then rm -rf ${temp} fi exit 0