Guy Rutenberg

Keeping track of what I do

Backup a SourceForge hosted SVN repository – sf-svn-backup

with 4 comments

SourceForge urges their users to backup the code repositories of their projects. As I have several projects hosted with SourceForge, I should do it too. Making the backups isn’t complicated at all, but because it isn’t automated properly, I’ve been lazy with it.

sf-svn-backup was written in order to simply automate the process. The script is pretty simple to use, just pass as the first argument the project name and the script will write down to stdout the dump file.

For example:

sf-svn-backup openyahtzee > openyahtzee.dump

The project name should be it’s UNIX name (e.g. openyahtzee and not Open Yahtzee). Because the script writes the dump file directly to stdout it’s easy to pipe the output first through a compression program such as gzip to create compressed SVN dump files.

Share and Enjoy:
  • del.icio.us
  • StumbleUpon
  • Digg
  • Facebook
  • Mixx
  • Google Bookmarks
  • Simpy

Written by Guy

December 12th, 2008 at 8:49 pm

Posted in Bash

Tagged with ,

4 Responses to 'Backup a SourceForge hosted SVN repository – sf-svn-backup'

Subscribe to comments with RSS or TrackBack to 'Backup a SourceForge hosted SVN repository – sf-svn-backup'.

  1. Hi Guy, I used your script and is apparently working well, I get a list of all the projects revision in the console and a file. I just have a question. How do you restore the dump file?

    Saul

    12 May 09 at 00:25

  2. To restore the dump file to a local repository you use

    svnadmin load /path/to/repo < dumpfile

    See
    $ svnadmin help load

    for more details.

    If you want to restore the repository to SF, as project administrator you have an option to import a dumpfile.

    Guy

    12 May 09 at 15:38

  3. Thank you very much. I appreciate your script. The dump-restore procedure worked well for me. I have not tried to restore to SF but I’m sure you have. (Ubuntu 9.04 64bit)

    Saul

    12 May 09 at 17:57

  4. Thanks bunches! That’s exactly what i’ve just been looking for.

    Chic

    23 Aug 09 at 21:41

Leave a Reply