[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Easiest way to move a branch to the trunk

From: Richard Cobbe
Subject: Re: Easiest way to move a branch to the trunk
Date: Fri, 2 Feb 2001 15:57:33 -0600 (CST)

Lo, on Friday, February 2, Brian J. Murrell did write:

> I have a project/repository which has a main branch (trunk) for
> stable, released versions and a development branch.  The development
> branch was branched off of the main branch a while ago for development
> and has going along gangbusters.  Now it is time to release.  What is
> the easiest way to move the develoment branch onto the main branch so
> that what is on the main branch is completely replaced by the
> development branch.

We're about to have to do this at work ourselves, because the folks who
created the branch didn't really understand what they were doing, and so
got the trunk & branch backwards.  (New development has been on the

If you tagged the trunk at the point where you branched, then this should
actually be pretty easy.  Call the tag PRE-BRANCH-TAG:

* Get a working copy on the trunk; make sure there are no uncommitted

* If you want to preserve that line of development, you may want to tag and
  branch here.

* Back on the trunk, roll back all changes made since the branch:
    cvs update -j HEAD -j PRE-BRANCH-TAG

* Resolve any conflicts, although I'd suspect that there wouldn't be any.
  You may also want to commit here, but that's up to you.

    to incorporate all changes made on the development branch.  Again,
    there shouldn't be any conflicts.

* commit.

If you *don't* have PRE-BRANCH-TAG, then you're up a creek, and you'll have
to go with one of the other more labor-intensive suggestions posted.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]