manatlan
manatlan

Reputation: 1131

TFS rebranch-ing?

In our TFS(2007), we've got this (bad) hierarchy :

$main
  |_ $V1
      |_ $V2

Ok ... it's a bad move from us.

Now, we'd like to have that :

$main
  |_ $V1
  |_ $V2

Is there a way to un-branch $V2 from $V1, and branch it to $main ?

Upvotes: 1

Views: 586

Answers (2)

kaepten
kaepten

Reputation: 3

With VS2013 and VS2012, there is a feature called Re-Parent. I never used it, but the documentation sais, that it's what you need... (IMO).

[Update for new VS-Versions]

Upvotes: 0

Nock
Nock

Reputation: 6609

First, TFS 2007 doesn't exist! :) Either 2005 or 2008.

Second, yes, it's a bad move.

Third, you can't change the relationship between branches, so you can't unbranch/rebranch.

Solution: You won't like it, but that's the only way to go, create the new proper hierarchy of branches then copy the content.

You can copy in many way, here's one:

  • First raw copy latest of source Main to destination Main
  • Merge from destination Main to destination V1, then check-in V1
  • raw copy latest source V1 to destination V1.
  • simulate a offline/online mode with TFPT online to compute the changes, then check-in
  • Do the same for V2.
  • If you want "snapshots" of your branch (not only the latest), you can simulate it by repeating the operation in chronological order.

If your project is big: good luck! (but you'll succeed and it's better now than later, trust me)

Upvotes: 1

Related Questions