info-cvs
[Top][All Lists]
Advanced

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

RE: Tagging across branches?


From: Jim.Hyslop
Subject: RE: Tagging across branches?
Date: Wed, 17 Mar 2004 09:22:53 -0500

Andy Jones wrote:
> I have a repository - that is, a subdirectory of $CVSROOT - 
> which has a number of subdirectories.
> 
> For one of these subdirectories I have created a branch, and 
> in my sandbox have checked out that branch.  So in my sandbox 
> I have the main trunk except for one directory, which is 
> sticky on a branch.
> 
> What happens if I "cvs tag" the entire sandbox?  
The tag will be applied to the revision that is checked out in your sandbox:
the trunk for most directories, the branch for your legacy directory.

> Can I do an export on that tag, and get exactly what I 
> currently see in the sandbox, including the branched directory?
Yes and no. The files will be restored exactly, but you will not have any of
the CVS directories. This means the files will no longer be under CVS
control.

> What happens if I do a checkout (!!) on that tag?
You will get exactly the files you currently have. Note, though, that all
the files will have the sticky tag set to your symbolic tag, so you will not
be able to continue development on these files.

> Some background, of you like: I have some legacy code from 
> before we started with CVS that only applies to one 
> directory, so I've put it in a branch (with the intention of 
> never, ever merging from that branch).   Now I need to make a 
> release to a site that is not ready to move on from that 
> legacy code.  So I want to make a "release tag" and do an export.
> 
> If I have cvs'd myself into a corner, suggestions for what I 
> *should* have done will be greatfully received...
Well, that depends what the intent is with the site that is using the legacy
code. If they will not be modifying the code, then your approach will work
fine, either by checking out or exporting (your choice).

If they will be modifying the code, then your approach will not work. They
will have to check out the branch tag for the legacy branch. You might want
to write a simple script or batch file that will check out the appropriate
directories for them, something like:

cvs co project
cd project
cvs update -r yourbranch legacy_directory

-- 
Jim Hyslop
Senior Software Designer
Leitch Technology International Inc. (http://www.leitch.com)
Columnist, C/C++ Users Journal (http://www.cuj.com/experts)






reply via email to

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