From: Eric Lujan Date: Wed, 2 Mar 2016 06:04:24 +0000 (-0500) Subject: Created rsync script to mirror MacPorts X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=2b6931ac56b5c5305826ccafa8303b092d2f5988;p=sipb-mirrors.git Created rsync script to mirror MacPorts Signed-off-by: Eric Lujan Signed-off-by: Lizhou Sha --- diff --git a/fetch-scripts/macports b/fetch-scripts/macports new file mode 100644 index 0000000..76cbd6d --- /dev/null +++ b/fetch-scripts/macports @@ -0,0 +1,17 @@ +#!/bin/sh + +RSYNCSOURCE="rsync://rsync-origin.macports.org" +BASEDIR="$MIRRORDIR/macports" + +RSYNC_MODULES="packages distfiles release trunk" + +RSYNC_ARGS="--compress --delete-delay --hard-links --links --no-motd --perms --recursive --stats --timeout=600 --times" + +for RSYNC_MODULE in $RSYNC_MODULES; do + RSYNC_URL="${RSYNCSOURCE}/${RSYNC_MODULE}" + echo "Syncing $RSYNC_MODULE from $RSYNC_URL" + mkdir -p "${BASEDIR}/${RSYNC_MODULE}" + rsync $RSYNC_ARGS "$RSYNC_URL" "$BASEDIR/$RSYNC_MODULE" + echo +done +