Click to See Complete Forum and Search --> : How to commit to multiple SVN repositories?
~*McoreD*~
Jan 18th, 2009, 07:41 PM
Hi,
I have a SVN setup in SourceForge for this C# project we have been working on.
http://zscreen.svn.sourceforge.net/viewvc/zscreen/trunk/
Recently we started migrating to Google Code slowly.
http://code.google.com/p/zscreen/source/browse/#svn/trunk/
Have no intention to close down SF yet and want to commit to both SVN Repos for the time being. Is this possible?
Thanks in advance,
McoreD
gep13
Jan 20th, 2009, 09:19 AM
Hey,
You can combine multiple projects in different repos using svn:externals, but I don't think that that is what you are after.
What you want to do is maintain the same code in two separate repos, so that they each have the same revisions, correct?
I haven't heard of that being done.
You can sync the two repos, would that help?
http://www.thoughtspark.org/node/10
Gary
~*McoreD*~
Jan 21st, 2009, 04:30 PM
Hi Gary,
YES! That's exactly what I need. I have two visual studio projects: One uses ImageUploader project in SourceForge, other uses ImageShack uploader in Google Code. I should be able to Update/Commit from both projects and both Google Code and SourceForge SVN Repos should be updated when I commit.
This looks too hardcore:
* Create your local repository: svnadmin create PATH
* Create an empty pre-revprop-change hook script: echo "#!/bin/bash" > PATH/hooks/pre-revprop-change
* Make the pre-commit-hook script executable: chmod +x PATH/hooks/pre-revprop-change
* Initialize svnsync: svnsync init file:⁄⁄⁄PATH URL_TO_REPO_ROOT_TO_CLONE
* Synchronize: svnsync sync PATH
Does this mean I need FTP access to do chmod operations etc? If so, I don't think I do have access like that to either Google Code or SourceForge.
Thanks.
gep13
Jan 22nd, 2009, 02:32 AM
Hey,
I have never used a remote Subversion repo, I use one locally on my own machine, so I have never had to do what you are suggesting. However, the concept behind Subversion, would suggest that what you are wanting to do is not possible. When you check out items, they are checked out from one place, and the changes that are made are compared against what is in that repo, and when you commit, you commit only to there.
I could be wrong about this, and maybe some reading of the SVN Red Book (http://svnbook.red-bean.com/) might reveal something.
I only other thing that I can think would be to always commit to one repo, then do a backup from there, and restore to your other repo.
This doesn't really get you what you are after though.
Gary
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.