{"thread":{"id":"28416","subject":"Most elegant way to reference to SVN from GIT?","startedAt":"2011-09-17T23:51:44Z","lastAt":"2011-09-18T18:47:07Z","messageCount":4,"participants":["Manuel Reimer","Jeff King","Jakub Narebski"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"175697","messageId":"j53c2h$gff$2@dough.gmane.org","threadId":"28416","inReplyTo":null,"subject":"Most elegant way to reference to SVN from GIT?","fromName":"Manuel Reimer","fromEmail":"manuel.spam@nurfuerspam.de","sentAt":"2011-09-17T23:51:44Z","receivedAt":"2011-09-17T23:51:44Z","isPatch":false,"sender":{"key":"manuel.spam@nurfuerspam.de","avatar":null},"body":"Hello,\n\nI'm using GIT for a project.\n\nNow someone offered to contribute a translation. This translation is hosted on a \nSVN server.\n\nHow can I get his work into my GIT tree and how can I keep things updated?\n\nThanks in advance\n\nYours\n\nManuel\n"},{"id":"175711","messageId":"20110918034318.GC17977@sigill.intra.peff.net","threadId":"28416","inReplyTo":"j53c2h$gff$2@dough.gmane.org","subject":"Re: Most elegant way to reference to SVN from GIT?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2011-09-18T03:43:18Z","receivedAt":"2011-09-18T03:43:18Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Sun, Sep 18, 2011 at 01:51:44AM +0200, Manuel Reimer wrote:\n\n> Now someone offered to contribute a translation. This translation is\n> hosted on a SVN server.\n> \n> How can I get his work into my GIT tree and how can I keep things updated?\n\nYou can pull their commits into git using git-svn, and then merge them.\nTry:\n\n  # make a new repo side by side with your project that contains\n  # their translation\n  cd /path/to/your-project/..\n  git svn clone https://host/their-subversion-repo their-translation\n\n  # inspect with \"git log\", \"ls\", etc to make sure it looks sane\n  # if so, then merge it in\n  cd ../your-project\n  git pull ../their-translation git-svn\n\n  # months later, get an update\n  cd their-translation\n  git svn fetch\n  cd ../your-project\n  git pull ../their-translation git-svn\n\nI think you could also do it all in one repo by using \"git svn init\" and\n\"git svn fetch\", but you'd have to check \"git help svn\" for the exact\nsyntax.\n\n-Peff\n"},{"id":"175713","messageId":"j54keg$ug9$1@dough.gmane.org","threadId":"28416","inReplyTo":"20110918034318.GC17977@sigill.intra.peff.net","subject":"Re: Most elegant way to reference to SVN from GIT?","fromName":"Manuel Reimer","fromEmail":"manuel.spam@nurfuerspam.de","sentAt":"2011-09-18T11:20:47Z","receivedAt":"2011-09-18T11:20:47Z","isPatch":false,"sender":{"key":"manuel.spam@nurfuerspam.de","avatar":null},"body":"Jeff King wrote:\n> You can pull their commits into git using git-svn, and then merge them.\n\nTried that, but maybe I did something wrong.\n\nIf I have a git-svn repo inside my git repo, then for some reason my own repo \ndoesn't known the git-svn repo. Means that I cannot push changes, that occured \nin the SVN repo, to my GIT server.\n\nSo I'm still searching for an elegant way to get SVN into my GIT repo. As \nsubmodules make it more difficult to clone the project, I think it would be nice \nto be just able to fetch the stuff from SVN \"commit by commit\" and then have \nthem as git commits in my own tree. So far I wasn't able to get this done...\n\nYours\n\nManuel\n"},{"id":"175727","messageId":"m3litlsn82.fsf@localhost.localdomain","threadId":"28416","inReplyTo":"j54keg$ug9$1@dough.gmane.org","subject":"Re: Most elegant way to reference to SVN from GIT?","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2011-09-18T18:47:07Z","receivedAt":"2011-09-18T18:47:07Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Manuel Reimer <Manuel.Spam@nurfuerspam.de> writes:\n> Jeff King wrote:\n\n> > You can pull their commits into git using git-svn, and then merge them.\n\nNb. there is also so called \"remote helper\" approach, where you can\nuse repositories using other SCM just like native remote Git\nrepositories.  But I think it is in early beta, or even alpha stages -\n- adding support for Subversion was this year Google Summer of Code\n2011 project.\n \n> Tried that, but maybe I did something wrong.\n> \n> If I have a git-svn repo inside my git repo, then for some reason my\n> own repo doesn't known the git-svn repo. Means that I cannot push\n> changes, that occured in the SVN repo, to my GIT server.\n\nErrr... isn't it more or less expected for _any_ remote repository\nadded, be it native (git) or Subversion one?\n\nRemote tracking branches are not usually pushed / fetched, unless you\nclone in a mirror mode, or set refspecs for fecthing / pushing by\nhand...\n\n-- \nJakub Narębski\n"}]}