Home > Archive > Unix Programming > June 2007 > CVS fetch the branch name with a tag name
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
CVS fetch the branch name with a tag name
|
|
| Bin Chen 2007-06-19, 4:16 am |
| Hi,
If I have a branch B_1 with revision 1.2.1.1 and have a tag T_1 in
1.2.1.3, which is under the branch B_1. How can I know the tag T_1's
branch name using CVS command?
What I want to achieve is, when I know a tag name T_1 for a module, I
want to check out the T_1 tag, then edit it, then commit it to the
branch B_1.
If I am using:
cvs up -r T_1
Then after editing, I commit, the cvs will say the tag is uneditable!
How to do this?
Thanks
Bin
| |
| Bruce Stephens 2007-06-21, 10:05 pm |
| Bin Chen <binary.chen@gmail.com> writes:
> If I have a branch B_1 with revision 1.2.1.1 and have a tag T_1 in
> 1.2.1.3, which is under the branch B_1. How can I know the tag T_1's
> branch name using CVS command?
>
> What I want to achieve is, when I know a tag name T_1 for a module, I
> want to check out the T_1 tag, then edit it, then commit it to the
> branch B_1.
Branches are linear in CVS. So if you want to commit to branch B_1,
you must commit to the head of B_1 (whether that happens to be T_1 or
not).
So the only way you can commit to B_1 is to check out the branch B_1:
cvs update -r B_1
If you want to replace the head of B_1 with some edited version of
what's at T_1, you could check out T_1 somewhere else and copy over
the files.
Or do "cvs diff -r T_1 | patch -p0 -R" to patch your B_1 checkout back
to T_1. Or use "cvs update" to do the same (I forget the exact way to
do that: something like "cvs update -j B_1 -j T_1").
| |
| Bin Chen 2007-06-21, 10:05 pm |
| On Jun 21, 6:39 am, Bruce Stephens <bruce+use...@cenderis.demon.co.uk>
wrote:
> Bin Chen <binary.c...@gmail.com> writes:
>
>
> Branches are linear in CVS. So if you want to commit to branch B_1,
> you must commit to the head of B_1 (whether that happens to be T_1 or
> not).
>
> So the only way you can commit to B_1 is to check out the branch B_1:
>
> cvs update -r B_1
>
> If you want to replace the head of B_1 with some edited version of
> what's at T_1, you could check out T_1 somewhere else and copy over
> the files.
>
> Or do "cvs diff -r T_1 | patch -p0 -R" to patch your B_1 checkout back
> to T_1. Or use "cvs update" to do the same (I forget the exact way to
> do that: something like "cvs update -j B_1 -j T_1").
Can I know a tag's branch name thru a CVS command?
|
|
|
|
|