Label issues

This forum is now locked, since Gold Support is no longer offered.

Moderator: SourceGear

Locked
ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Label issues

Post by ajj3085 » Fri Jul 21, 2006 1:20 pm

Hi,

I've created a new project and moved some files from an existing project into this project using the File -> Move command (I'm relocating these to a new, seperate assembly).

The problem is that my build is failing, because it can't label the file; looking at the file's history, al the old labels from the previous project are still there, and I can't remove teh labels.

What can i do? The labels are generated as part of my build process, and indicate a version from the build server.

Thanks
Andy

jclausius
Posts: 3702
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
Contact:

Post by jclausius » Fri Jul 21, 2006 1:32 pm

I'm not certain I understand your scenario. Does it look something like this?

A file - foo.c (version 1) is under $/A/, and $/A/ is labeled 'mylabel'. Next foo.c is modified and then moved to $/B/ (foo.c - version 2). A label on B for 'mylabel' will fail because foo.c version 1 already has a label named 'mylabel'.

In a case like this, the second label is disallowed as a label's name must be unique for any given version of the file. In a case like this, either the label name must change, or the file must be removed from the original label.
Jeff Clausius
SourceGear

ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Post by ajj3085 » Fri Jul 21, 2006 1:39 pm

jclausius wrote:A file - foo.c (version 1) is under $/A/, and $/A/ is labeled 'mylabel'. Next foo.c is modified and then moved to $/B/ (foo.c - version 2). A label on B for 'mylabel' will fail because foo.c version 1 already has a label named 'mylabel'.

In a case like this, the second label is disallowed as a label's name must be unique for any given version of the file. In a case like this, either the label name must change, or the file must be removed from the original label.
Pretty much, except foo.c is moved without being modified. So how do I remove foo.c from the label? Deleting the label isn't an option, nor is changing the label (the label corrispond to assembly version numbers).

jclausius
Posts: 3702
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
Contact:

Post by jclausius » Fri Jul 21, 2006 1:59 pm

I think you may have misunderstood. The version of foo.c in 'mylabel' must be the same version of foo.c in the new folder location. So, if foo.c has been modified since the first 'mylabel' as applied, the new label will fail. This is because 'mylabel' represents version 1 of the file. It cannot represent any other version of foo.c.


If you cannot delete the label, remove the file from the label, or promote the version of the file to the same version you are now trying to label, then the only alternative is to use a different label name.
Jeff Clausius
SourceGear

ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Post by ajj3085 » Fri Jul 21, 2006 2:10 pm

jclausius wrote:If you cannot delete the label, remove the file from the label, or promote the version of the file to the same version you are now trying to label, then the only alternative is to use a different label name.
Removing the file from the label is fine, I'd like to know how to do that, as I didn't see a way.

jclausius
Posts: 3702
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
Contact:

Post by jclausius » Fri Jul 21, 2006 2:13 pm

Show Labels on the original folder which was labeled. Go into Label Promotion, and remove the file from the label.
Jeff Clausius
SourceGear

ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Post by ajj3085 » Fri Jul 21, 2006 2:20 pm

jclausius wrote:Show Labels on the original folder which was labeled. Go into Label Promotion, and remove the file from the label.
Ahh, very cool, I didn't know about that feature.

Thanks for your help; I'll have to remember to think of Labels more as containers than a tag.

jclausius
Posts: 3702
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
Contact:

Post by jclausius » Fri Jul 21, 2006 2:43 pm

That is a good analogy. A label is basically a reference to a given version of a file or folder.
Jeff Clausius
SourceGear

Locked