Disclaimer

The content of this blog is my personal opinion only. Although I am an employee - currently of Nvidia, in the past of other companies such as Iagination Technologies, MIPS, Intellectual Ventures, Intel, AMD, Motorola, and Gould - I reveal this only so that the reader may account for any possible bias I may have towards my employer's products. The statements I make here in no way represent my employer's position, nor am I authorized to speak on behalf of my employer. In fact, this posting may not even represent my personal opinion, since occasionally I play devil's advocate.

See http://docs.google.com/View?id=dcxddbtr_23cg5thdfj for photo credits.

Monday, January 02, 2012

Recovering diverged home directory version control

I have long version controlled my home directory.  CVS. Git. Hg.

Unfortunately, they diverged.  Divergence happens naturally with CVS.  You have to work hard to get git and hg to diverge, but I did.

Now I want to merge the diverged home directories back together.  Preserving the history if possible, from the different VCS.  Sometimes just merging fikes.

==

Today: I want to start merging a diverged linux tree, from a flash drive, with my working tree (which started off on cygwin).

I created a new hg repo, created a branch on it, and then imported the tree to be merged.

I pulled/pushed this with my main home hg repo.  Had to use -f, to force unrelated repos to be together.

Now I have a single repo, with my current working (cygwin derived, homedir, and a not working linux homedir, on different branches.  The former n the default branch.

That's okay.  Not so bad.  A single history object(although I have kept separate working space trees.)

===

Now I want to merge, a file or a few files at a time.

E.g. copy the README from the linux branch to the default working derived from cygwin branch.


AAARGH!!!!  Hg doesn't handle partials... neither merges, not copies, nor...  Hg just plain really wants to lose track, not make doing this activity easy.

No comments: