blob: 1139295f2deb2e6f902be201532fe2d1d7ce48ed [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en">
<HEAD>
<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2005. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<LINK REL="STYLESHEET" HREF="../book.css" CHARSET="ISO-8859-1" TYPE="text/css">
<title>Moving version tags</title>
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>Moving version tags</H1>
<p>Warning: Although many people would prefer a CVS version to be frozen in time and not be modifiable, version and branch tags in CVS are mutable. As a result many are convinced that modifying a version is bad practice, but there are a couple of scenarios where it actually comes in handy. With that said, please be cautious when moving tags around.</p>
<h2>Moving a tag on a single file</h2>
<p>Let's say that you have just submitted your build by versioning your project
as R1. But you soon after discover that there is a small change to a file that
should be made and included in the build. Instead of having to re-version the
project you can move the R1 version tag for the modified file.</p>
<ol>
<li>Modify the file(s) Select the file that was modified after R1 was created
and from the context menu select <strong>Team &gt; Show in Resource History</strong>.</li>
<li>From within the Resource History view select the revision that should be
marked with the R1 version. </li>
<li>From the context menu select <strong>Tag with Existing...</strong>.</li>
<li>Select the R1 version from the dialog box and press OK. </li>
<li>The resource history view will be updated to confirm that the version had
been moved.</li>
</ol>
<h2>Moving a tag from within the repositories view</h2>
<p>Many projects use a well defined version name for their current stable lineup in HEAD. For example, by versioning HEAD with the STABLE tag the build scripts could simply checkout the STABLE version for builds. As the code evolves the STABLE tag is moved regularly to mark the most current stable lineup. The repositories view provides an action for moving an existing tag.
</p>
<ol>
<li>Open the Repositories view and select a resource.</li>
<li>From the context menu select <b>Tag with Existing</b></li>
<li>A tag selection dialog will appear from which you can select the tag to move. If the tag you wish to apply is not show in the list, you can click <b>Refresh from Repository</b>. If this doesn't find the tag, you can click <b>Configure Tags</b> which opens a dialog that allows you to search for tags on specific files in the repository.</li>
<li>Then press <b>OK</b> and your tag will be moved. The operation will move an existing tag to the selected resources and can be used to move both version and branch tags.</li>
</ol>
<p><img border="0" src="../images/ngrelc.png" alt="Related concepts" ><br>
<a href="../concepts/concepts-26.htm">Team programming with CVS</a>
</p>
<p><img border="0" src="../images/ngrelt.png" alt="Related tasks" ><br>
<a href="tasks-115.htm">Synchronizing with the repository</a><br>
<a href="tasks-114.htm">Committing</a>
</p>
</BODY>
</HTML>