Subject: Re: rsync for pkgsrc? (was Re: updating packages)
To: None <netbsd-users@netbsd.org>
From: Chris Baird <cjb@brushtail.apana.org.au>
List: netbsd-users
Date: 12/15/2001 06:25:13
Here's the script that I've used for several months, if it can be
useful to anyone.

Using "rsync --delete" will quite happily delete anything, including
that 2.3Gig of source code you've downloaded over a modem in the past
year into distfiles/. I keep my distfiles and packages directories in
different location, so I only have to restore the softlinks.

    #!/bin/sh
    cd /usr/src/pkgsrc
    rsync --exclude "CVS/" --delete -prztvv \
        rsync.jp.netbsd.org::NetBSD/NetBSD-current/pkgsrc/ .
    #
    rmdir /usr/src/pkgsrc/distfiles /usr/src/pkgsrc/packages
    ln -s /export/src/distfiles /usr/src/pkgsrc/distfiles
    ln -s /export/src/packages /usr/src/pkgsrc/pkgsrc/packages

-- 
Chris Baird,, <cjb@brushtail.apana.org.au>