#!/bin/sh ORIG=/Volumes/GARMIN/ DIST=/Volumes/mitsukuni.sato/Documents/ if [ ! -d ${DIST} ]; then /bin/echo -n "MobileMe disk is not mounted" exit fi rsync \ -avz \ --exclude=Desktop \ ${ORIG}/* \ ${DIST} find ${ORIG}/Garmin/History/ -mtime +8w -depth 1 -type f -exec rm {} \;