SVN When you tag a working copy, is it still a cheap copy?

Using Subversion, in my working copy I make a small modification (update the version number). I would like to tag my working copy. Will this tag still be a cheap copy with modification, or will SVN duplicate files? I would really like to see that my repository is growing rapidly in size, because I'm trying to save a change in version number.

The reason I ask about creating a tag that contains a modification, not a commit, then tagging includes my build server. The build server creates CCNetLabel, which I use to update the version numbers of my projects (AssemblyInfo.cs). When the assembly is successful, a tag is created. When I use ForceBuild, the tag is based on a working copy that will contain the modified version number. I want the tag to contain the corresponding version number.

Note: This is debatable if I create a branch or tag, however SVN does not distinguish between the two.

+6
branch svn tags
source share
4 answers

It depends. If your working copy is updated (all nodes have the same revision), it is just as cheap as tagging from the repository.

For each file / directory (or actual subtree) with a different version than its parent additional data will be added. And if you have local modifications, more data will be added.

But still reasonably cheap: it does not duplicate files that are already in the repository.

+4
source share

From the description of subversion

  • Branching and tagging are cheap (constant time) operations. There is no reason for these operations to be expensive, so this is not so. Branches and tags are implemented as part of the main copy operation. A copy takes up a small, constant amount of space. Any copy is a tag; and if you start to copy, then this is also a branch. (This eliminates the β€œbranching” CVS tags, eliminating the differences that branch point labels primarily made.)

Attention! I just noticed that Subversion was ported to the organization of the Apache project

+5
source share

Creating a tag or branch in subversion is very cheap. Files will not be copied. All that happens is that a new revision will be created, the content of which basically just contains a pointer to where the tag was copied from. This will be the same size for the project tag with one small file or for one with a million large.

When you say "tag my working copy," do you mean "tag my working branch"? You can only mark data that has already been committed to the repository, and not local uncommitted changes.

+1
source share

A rather outdated publication, but it is worth mentioning for those who visit this answer, stating that you can only "You can only tag data that has already been transferred to the repository ...", the perfect work is not entirely accurate (at least not currently).

You can mark a working copy, which may contain mixed versions and even switchable directories, as well as local modifications.

As for cheapness, yes, it should be cheap, since Subversion will work for you and then overlays your working copies on the repo, saving as much space as possible

+1
source share

All Articles