"Hg to Hg (Gateway) to SVN" compared to "Git to Git (Gateway) to SVN" -


question similar this (unanswered) , this one (same problem not involving git).

the goal make hg front end svn period of time before transitioning hg.

the setup should 1 depicted below (same in questions referenced above), i'm not sure exact topology of intermediate hg repositories.

dev1 hg --> hg <--> svn dev2 hg -/ 

i know above setup works git , git-svn described in this comment:

dev1 git --> git (bare) <--> git (bridge) <--> svn dev2 git -/ 

setup:

  1. either git svn init, or git svn clone svn repo. becomes “git/svn bridge.”

  2. fix of branches, tags, etc… here. svn/* refs considered remotes, if want tracking branches, check these remotes out , create appropriate local branches. also, check tags out, , create actual tags. must create local branches svn branches wish synchronize between git , svn.

  3. now, create new bare repository (git init) somewhere, , bridge, push branches bare repo (git push –tags).

  4. all git users clone bare repository. bridge maintained 1 (or few) people understand how synchronize git , svn.

to update svn trunk changes on master, , vice-versa, bridge:

  1. git svn fetch (get new svn changes)

  2. git checkout master

  3. git pull master (get git changes bare repo)

  4. git checkout svn/trunk (checkout detached head)

  5. git merge –no-ff –log master (merge changes master). –no-ff insures actual commit, –log copies individual log messages each commit on master (–log optional). git commit –amend can run if want edit commit message.

  6. git svn dcommit (this pushes merge commit svn. note commit on detached head, , no longer accessible). of work on master (since merge-base of master , svn/trunk) gets committed single change, , available svn users.

  7. git checkout master

  8. git merge svn/trunk (gets new updates svn – altered commit message – , merges master)

  9. git push barerepo (makes svn changes available git users)

what don't know if it's possible somehow replicate above on hg. see (i'm intermediate git user , know basics of working hg), obstacles in hg are:

  • no remote-tracking branches (is possible bookmarks? separate cloned repos?)
  • impossible push merge commits via hgsubversion (step n. 6 in above list. stops hgsubversion doing svn dcommit does?)

is possible make hg-svn gateway work in same fashion git-svn gateway works? if no, why?

the short version is: nobody's yet convinced me reasonable expected behavior of pushing merge subversion should be, , there slight modifications hgsubversion advisable make pushing result in merges rather rebased revisions. none of should hard, takes motivated implementation. if you're curious, this thread has similar request responded in-depth discussion of basic approach i've thought through couple of others.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -