Simetrical wrote:
Somewhat didn't realize that tags aren't supposed to be modified once they're created. :) (...) Well, no, it really means don't touch them *ever*. They're meant to be particular snapshots. If you release a new version or something, you create a new tag, you don't touch the existing ones. Otherwise it defeats the point; you should just use a branch instead.
Most tags, specifically tags intended to mark releases, milestones and snapshots.
One of the most interesting things about Subversion is that tags are versioned, like everything else. There are a few cases where you actually want a tag to change and move around. Tracing merges is one of them:
http://subversion.tigris.org/faq.html#merge-using-tags
Until Subversion 1.5 is released (with good builtin merge tracking), this is a very useful trick (if you do a lot of merging between branches, you may want to look at svnmerge.py).
It is possible to forcefully restrict changes to tags once they are created by using a simple pre-commit Subversion hook:
svnlook changed -t $2 $1 | grep "^U\W+tags/" && \ echo "Tags cannot be modified." 1>&2 && \ exit 1
You may want to change the regular expression to match your repository structure.
This wont restrict tag creation and deletion, just modification of their contents. So, if you create a broken tag, you just delete it and create it again.