{"thread":{"id":"24888","subject":"Git-SVN & subdirectory branches","startedAt":"2010-08-27T16:37:42Z","lastAt":"2010-08-28T01:45:08Z","messageCount":2,"participants":["Brian Gernhardt","Jonathan Nieder"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"149128","messageId":"F393D37F-9BDE-4F29-94E9-806AF88D1A30@gernhardtsoftware.com","threadId":"24888","inReplyTo":null,"subject":"Git-SVN & subdirectory branches","fromName":"Brian Gernhardt","fromEmail":"brian@gernhardtsoftware.com","sentAt":"2010-08-27T16:37:42Z","receivedAt":"2010-08-27T16:37:42Z","isPatch":false,"sender":{"key":"brian@gernhardtsoftware.com","avatar":"https://avatars.githubusercontent.com/u/133455?v=4"},"body":"I'm working on creating a git mirror of the MINIX 3 repository.  I'm encountering a problem with the fact that the branches and tags often but not always are based on a subdirectory of trunk.  It appears that when git-svn encounters one of these branches it starts over from revision 1.  Is there a good way to deal with this or should I just let git-svn clone it as it will and use something like filter-branch to clean it up?  (Note that I intend this to be an ongoing mirror so any solution has to let git-svn work properly afterwords.)\n\nIn particular, MINIX's trunk contains a bigports and a src subdirectory and some branches (and tags) have both subdirectories, but more often they branch just the src (kernel and servers) directory.\n\nFor visual learners:\n\n/trunk\n  /bigports\n  /src\n    /boot\n    /commands\n    ...\n/branches\n  /R3.1.0\n    /bigports\n    /src\n  /R3.1.7\n    /boot\n    /commands\n    ...\n\nThe SVN repo can be browsed at https://gforge.cs.vu.nl/gf/project/minix/scmsvn/?action=browse&path=/ but people should be careful trying to clone it fully using git-svn due to the issue above.  I finally just used svnsync to create a local copy to clone from.\n\n~~ Brian"},{"id":"149149","messageId":"20100828014508.GC2004@burratino","threadId":"24888","inReplyTo":"F393D37F-9BDE-4F29-94E9-806AF88D1A30@gernhardtsoftware.com","subject":"Re: Git-SVN & subdirectory branches","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-08-28T01:45:08Z","receivedAt":"2010-08-28T01:45:08Z","isPatch":false,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Hi,\n\nBrian Gernhardt wrote:\n\n> For visual learners:\n> \n> /trunk\n>   /bigports\n>   /src\n>     /boot\n>     /commands\n>     ...\n> /branches\n>   /R3.1.0\n>     /bigports\n>     /src\n>   /R3.1.7\n>     /boot\n>     /commands\n>     ...\n\nRight, I don't think git svn has any logic for this.  If you want to track\nbranches like R3.1.7 keeping the layout of trunk, you'll have to patch\ngit svn.\n"}]}