Using Labels with Deleted Files

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
tdginctr
Posts: 1
Joined: Tue Nov 09, 2004 8:06 pm

Using Labels with Deleted Files

Post by tdginctr » Tue Mar 06, 2007 11:08 pm

Let's suppose that I have a repository containing folder "My Project". I want to checkin the source files for "Release 1" and they happen to be file1.c, file2.c and file3.c. I then add the label "Release 1" to the "My Project" folder. Next, I complete Release 2 and want to check in the project files. This release of the project no longer uses source file "file1.c", so the files that I checkin are file2.c and file3.c. I then add the label "Release 2" to the "My Project" folder.

The problem is that if I do a GET using label "Release 2", my working folder will contain file1.c, file2.c and file3.c. But that particular release not supposed to include file1.c - it was not part of the checkin for that release. Is there any way to prevent an "obsolete" file from being retrieved, other than manually excluding this file from the label? Because that's fine for 1 file but not if you've got multiple "obsolete" files.

Thanks in advance for your help.
Tom Ross
Terminal Development Group Inc.

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Post by lbauer » Wed Mar 07, 2007 8:47 am

A folder labels a particular version of a folder, and represents the state of the folder at the point of the label, with all the file contents, not just the latest change set or checkin.

If file.c is no longer part of the release, you can delete (but not obliterate) the file. It will be gone from the current project, but when you do a get by label on Release 1, the project will be retrieved with that file, since it existed at the time of the label.

Another option is to branch to create Release 2, and delete the obsolete file.

More info on best practices here:
http://support.sourcegear.com/viewtopic.php?t=193
http://support.sourcegear.com/viewtopic.php?t=9
Linda Bauer
SourceGear
Technical Support Manager

Post Reply