svn Using tags


Example

"Tags" are a type of label that can be applied to a repository at a certain point in time. They are frequently used to give human-readable names to important milestones so that they can be easily accessed later (for example, "version-1.2").

Creating a tag is exactly the same as creating a branch:

svn copy -r 1234 ^/MyProject/trunk ^/MyProject/tags/version-1.2

In this specific case, the -r 1234 argument was used to indicate that the tag should be created from revision 1234 of the trunk.

Subversion doesn't make any distinction between a tag and an ordinary branch. The only difference is in how you decide to use them. Traditionally, no commits are made to a tag once it has been created (to ensure that it remains an accurate "snapshot" of a past repository state). Subversion doesn't enforce any special tag-related rules by default since different people can use tags differently. A repository administrator can, however, set up access control scripts to enforce whatever rules their team has decided to use.

In Windows, you need to use a double caret ^^.