#!/bin/sh function create { mkdir temp123 cd temp123 svn export svn://localhost/repos/misc/3d tar cjf 3d.tar.gz 3d mv 3d.tar.gz ../ cd .. rm -rf temp123 echo Distribution created as 3d.tar.gz } function publish { chmod 644 3d.tar.gz scp 3d.tar.gz cs6rlw@linux01.csc.liv.ac.uk:public_html/3d.tar.gz } if (( ${#1} == 0 )) then create else create && publish fi