{"thread":{"id":"22765","subject":"[Git-SVN] Manage merges bewteen remote branches. git-svn or svn?","startedAt":"2010-02-23T11:58:31Z","lastAt":"2010-02-23T11:58:31Z","messageCount":1,"participants":["Daniele Segato"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"135416","messageId":"9accb4401002230358k669937fai400890658b14c4fb@mail.gmail.com","threadId":"22765","inReplyTo":null,"subject":"[Git-SVN] Manage merges bewteen remote branches. git-svn or svn?","fromName":"Daniele Segato","fromEmail":"daniele.bilug@gmail.com","sentAt":"2010-02-23T11:58:31Z","receivedAt":"2010-02-23T11:58:31Z","isPatch":false,"sender":{"key":"daniele.bilug@gmail.com","avatar":null},"body":"I'm trying to understand the best way to deal with remote branches\nmerging in git-svn.\n\nThis is the situation (more or less) that I had to manage:\n\nmaster: tracking remote svn trunk\nv1.x: tracking remote svn branches/v1.x\n\nat the moment v1.x just branched from trunk\n\nmaster\n    |\n    |\n    |\n    |   v1.x\n    |  /\n    | /\n    |/\nbranch point\n\n\nnow i should start to merge into v1.x the work from trunk/master.\nsome of the last commit on master will be left there for later merging.\n\nso i branched from master~10 (example) and cherry-picket the commit i\nwant to put into\n\n\nI see three root from now on and no one i really like:\n1.\ngit checkout v1.x\ngit merge --squash myTemporaryBranch\n\nthis way it's ok the first time but i'll have a lot of conflict later\nwhen i will do (again):\ngit merge --squash master\n\n\n2.\ngit checkout v1.x\n# this will not work because of the svnid:\n#git rebase myTemporaryBranch\n\nso I did:\nfor commit in `git rev-list --reverse --cherry-pick\nv1.x..myTemporaryBranch`; do\n    git cherry-pick-svn $commit;\ndone;\n\nthe cherry-pick-svn is an alias i defined myself like this:\ncherry-pick-svn =  !GIT_EDITOR='sed -i /^git-svn-id:/d' git cherry-pick -e\n\nit just strip out the git-svn-id line from the commit comment.\n\nthis way i have all the history but i think i'll have conflict any\nway, can you confirm?\nfurthermore it will take a lot of space into the SVN server.\n\n3.\nuse svn directly.\nnever did an svn merge with svn so I still don't know exactly how it work\nmay be someone of you can tell me if this could work or not. this way\nI should always do my mergings with subversion directly\n\n\n\nWhat would you do?\nthanks and regards,\nDaniele Segato\n"}]}