Kyle V.
Kyle V.

Reputation: 4802

Branching to an older changeset in-place?

I have a TFS Team Project named "Project" with one folder called "Main".

I have already started development on Project 2.0 and I failed to branch Main before starting new development. Basically, I would like to have it as if I had branched Main at the end of development of 1.0 right before development of 2.0 started. The reason for this is Project 2.0 is being discontinued and I want to be able to start from where I ended with 1.0 but I don't want to rollback the entire Main folder and effectively lose all 2.0 history.

Is there a way to do this? I want "Project" to the the trunk, with its Main folder starting at the Changeset associated with the end of 1.0 development and I want to make a new Team Project called "Project 2.0" which will have its Main be as if I had branched it at the end of 1.0 and to maintain all history as if 2.0 was never cancelled.

Thanks in advance!

Upvotes: 1

Views: 139

Answers (1)

PatrickLu-MSFT
PatrickLu-MSFT

Reputation: 51183

I'm not sure if I understood your point correctly. Seems you want to create branch at specific changeset, move changests after this point to different branch.

Your needs:

Reset your main branch to a particular changeset - 1000( the end of development of 1.0). For Changesets after 1000, you want to move to a new branch (for maintain all history)

This is not possible for Team Foundation Version Control with a simple command or branch option.

You should take a copy of your code, and roll back the change. Then create a branch and overwrite the changes that you copied.

If you just want to branch your main at a specific changeset, this could be achieved, please see the answer in Can a branch be made from a previous changeset?

enter image description here

Upvotes: 1

Related Questions