Ask a questionAsk a question
 

AnswerGet all project files from label?

  • Tuesday, September 18, 2007 11:31 PMxr280xr Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Hi, I don't know much about SourceSafe, but I am trying to get all of my project's files from a label (I basically want to do a local rollback of the code). I created a label after publishing an application. Then made some changes to a few files and checked them in via VS 2005. How can I revert all of the project files back to the version I labeled rather than getting them one at a time?

Answers

  • Thursday, September 20, 2007 5:36 PMPatrick MCCormick Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Right click on the folder the label was added and select show history. (Make sure show labels is select you do not need file history) Select the project label in the history and choose get.

     

    At that point you can change the path for the get or select a working directory.

     

    Remember to choose recursive. Normally selecting build tree is also good practice.

     

    Let me know if this helps or if you require addtional detail.

     

  • Friday, September 21, 2007 4:05 PMPatrick MCCormick Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hi,

     

    Build tree forces the tree structure in SourceSafe to be reflected on disk.

    eg.

    getting $/project1 to c\..\project1 results

    $/project1/test1

                   test2

     

    become

    c:\...\project1\test1

                         test2

     

    As one would naturally expect.

    It is however possible in Sourcesafe to set an explicit working directory for test1 and tes2 to point to somewhere entirely different on your hard drive.

     

    such that

     

    $/project1/test1  maps to c:\joe1

    $/project1/test2 maps to  c:\jim1\my documents\test1

     

    Checking build tree ensure that you get the tree structure you typically expect rather than retrieving to the working directories on lower level subprojects which may be set to unanticipated locations.

     

    Typical you do not run into problems where the lower level directories are set to something different but build tree assures this.

     

    I hope this is a clear explanation.  Please let me know.

     

All Replies

  • Wednesday, September 19, 2007 3:45 PMPatrick MCCormick Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

     

     

    I would suggest a virtual rollback. 

     Do a get on the project label to a specified Directory.

    Do a checkout to the same directory marking the don't get local file option and checkin.

     

    I would test and then re-label.

     

  • Wednesday, September 19, 2007 4:54 PMxr280xr Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Thanks for your response. I think the first part was what I was trying to ask. How do I do a get on the project label to a specified directory?

  • Thursday, September 20, 2007 5:26 PMRichard BergModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    1. Rightclick a project in VSS Explorer -> Show History
    2. Check "include labels", push OK
    3. Select the label from the list, hit Get
    4. Check "recursive", push OK
  • Thursday, September 20, 2007 5:36 PMPatrick MCCormick Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Right click on the folder the label was added and select show history. (Make sure show labels is select you do not need file history) Select the project label in the history and choose get.

     

    At that point you can change the path for the get or select a working directory.

     

    Remember to choose recursive. Normally selecting build tree is also good practice.

     

    Let me know if this helps or if you require addtional detail.

     

  • Thursday, September 20, 2007 10:57 PMxr280xr Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Thanks, I thought I had tried that before, but I must not have had recursive checked. I read the description in help about "Build Tree" but it's not much of a description. Why is it good practice?

  • Friday, September 21, 2007 4:05 PMPatrick MCCormick Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hi,

     

    Build tree forces the tree structure in SourceSafe to be reflected on disk.

    eg.

    getting $/project1 to c\..\project1 results

    $/project1/test1

                   test2

     

    become

    c:\...\project1\test1

                         test2

     

    As one would naturally expect.

    It is however possible in Sourcesafe to set an explicit working directory for test1 and tes2 to point to somewhere entirely different on your hard drive.

     

    such that

     

    $/project1/test1  maps to c:\joe1

    $/project1/test2 maps to  c:\jim1\my documents\test1

     

    Checking build tree ensure that you get the tree structure you typically expect rather than retrieving to the working directories on lower level subprojects which may be set to unanticipated locations.

     

    Typical you do not run into problems where the lower level directories are set to something different but build tree assures this.

     

    I hope this is a clear explanation.  Please let me know.

     

  • Monday, September 24, 2007 4:26 PMxr280xr Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Good explanation, great to know. Thank you!