tags:

views:

40

answers:

0

Hello

Scenario:

I have a Git Repo hosted in GitHub: http s://[email protected]/Nerian/JPovray.git

Which can be accessed by SVN clients at: htt p://svn.github.com/Nerian/JPovray.git

And I have another SVN server hosted in school servers. I want this server to be a mirror from the repo at GitHub.

It is a school requirement to use the SVN repo at school.

Test:

#Create the mirror repo
svnadmin create dest

#Make the hooks always pass
echo "#!/bin/sh" > dest/hooks/pre-revprop-change
echo "#!/bin/sh" > dest/hooks/start-commit    

#Make the hooks executable
chmod +x dest/hooks/pre-revprop-change dest/hooks/start-commit

#Initialize the mirror repo to mirror the github repo
svnsync init file://`pwd`/dest http://svn.github.com/Nerian/JPovray.git 

It gives me this message :

svnsync: Storage of non-regular property 'svn:wc:ra_dav:version-url' is disallowed through the repository interface, and could indicate a bug in your client

#Start the mirroring process 
svnsync sync file://`pwd`/dest

It gives me this message:

svnsync: REPORT of 'http://svn.github.com/Nerian/JPovray.git': 200 OK (http://svn.github.com)

#Checkout the mirror repo.
svn checkout file://`pwd`/dest client

It gives me the message:

Checked out revision 0.

Currently, there are 6 revisions on the Github repo. The checkout say there are 0. So it means the sync didn't work. The client repo is empty, while the Github repo has 2 two files.

Constrains:

It is possible to run commands in the SVN repo at school, I just have to contact the SVN manager.

The commit history of the GitHub repo must be keep. We are a team of 3 members and the professor needs to know who commit what.

I hope you can help me, Thank you.

EDIT:

I contacted GitHub about this, and they told that it is not possible to mirror a GitHub svn repo because they are not really subversion repos. It's just some sort of bridge.

So I have started programming a solution:

http://github.com/Nerian/github_subversion_converter

This Ruby application will allow transferring commits from one SVN to another one. Currently, as of 23 october 2010 it do its job. But doesn't preserve Commit Author name. I am working in that. Should be feature complete in a week. For the current status, check the repo page.

See you.