Redo a build?

Hi,

I have a very stupid question, but certainly very important and usefull :-)

How can you redo a specific build with team foundation server

It is possible to get a specific version based on label on the client side or on the TF server, but I don't see how to say "Get that version and build again it!" :-)

Thanks in advance,

Steeve

PS: Well in fact I can see a "non easy and manual way":

  • 1. Create a specific build type specifcally for that where
    • Sources are never retreived from TF (using some skip properties),
    • Labelling is not performed,
    • Work items should not be updated.
  • 2. Each time there is a need: logon Build Server and get files based on label in the workspace of that build type



Answer this question

Redo a build?

  • Peter Grieg55

    There certainly is a way though not as easy as clicking on the menu command.

    The Get task of TFS supports getting files based on version, label, date etc. Check out this blog - http://blogs.msdn.com/nagarajp/archive/2005/10/21/483590.aspx

    So, in your case the steps will be -

    1. One time operation -
      • Create a build type through wizard.
      • Modify it to get files based on label. If the label to get is not fixed, then use a property say $(LabelToGet) instead of hard-coding.
      • Yes, you might also have to set Skip flags for not updating work items if you want that.
      • Add following line to TFSBuild.rsp file
        • /p:LabelToGet:MyLabel
    2. Each time
      • Edit the TFSBuild.rsp file to fix MyLabel value.

    Note that for each build, TB labels the sources with the build number.

    Thanks,

    Gautam


  • Redo a build?