[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Copy from a branch into working dir?
From: |
Jim Hyslop |
Subject: |
Re: Copy from a branch into working dir? |
Date: |
Mon, 17 Oct 2005 23:43:50 -0400 |
User-agent: |
Mozilla Thunderbird 1.0.6 (Windows/20050716) |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
address@hidden wrote:
> Can someone tell me how to update my working copy of a file with a
> particular revision/branch, and not make it sticky? I don't want to
> merge changes; I just want to replace my version with the one I
> request.
You can use the two-option merge for this. If TARGET_REVISION is the
revision that is to be replaced, and SOURCE_REVISION is the revision
that is to be used, then make TARGET_REVISION the current revision and
issue a merge:
cvs update -rTARGET_REVISION
(`cvs update -A` if TARGET_REVISION is the head of the trunk)
cvs update -jTARGET_REVISION -jSOURCE_REVISION
Example 1: to replace the trunk revision with the tip of ABRANCH, then
the command would be:
cvs update -A
cvs update -jHEAD -jABRANCH
Example 2: to copy the tip of BRANCH1 into the tip of BRANCH2:
cvs update -rBRANCH2
cvs update -jBRANCH2 -jBRANCH1
Example 3: to replace HEAD with a specific symbolic tag, say REV_1_2_3
(it doesn't matter if this tag is on a branch or on the trunk):
cvs update -A
cvs update -jHEAD -jREV_1_2_3
- --
Jim Hyslop
Better software. Simply.
Dreampossible <http://www.dreampossible.ca>
GPG Key fingerprint = 7938 3894 6C5A 4451 647E 0387 2DD0 F20F 0C89 C3E3
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFDVG92LdDyDwyJw+MRAp/FAKDpm8Q/KXM7u64e5ticuIKFUELkugCcDgba
nlKZ48Gvw1vYwmwIVopqP7M=
=unCv
-----END PGP SIGNATURE-----