7

I want to change the default priority of a build definition (the build is triggered each check-ins). How do I do that?

2 Answers 2

4

The correct use of the MSBuild priority argument is:

/p:Priority=High
1
  • Agreed, I tried this as well and it did not influence the priority of a TFS build. Aug 28, 2013 at 19:09
-2

So the build definition you want to change is a CI build. Right click the build definition and click edit. Go to the process tab (hopefully you are using the default template the comes with TFS 2010, see this walkthrough on MSDN on how to edit a build definition http://msdn.microsoft.com/en-us/library/dd647547.aspx) and look for the MSBUILD arguments. Add the switch /priority:priority

priority: Queue priority to use for the build definition. You use this argument with the /priority option. Valid values are Low, BelowNormal, Normal, AboveNormal, and High.

See other msbuild switches, http://msdn.microsoft.com/en-us/library/ms181742.aspx

HTH Cheers, Tarun

7
  • I tried it and it didn't work. I think you gave me the wrong link, you wrote me to edit the msbuild params but gave me a link to the "TFSBuild start" command. I think that the only way is to edit the defualt template am I right?
    – Clueless
    Jul 17, 2011 at 14:22
  • So, u have added /priority:High in your CI build in the MSBuild Argument parameter under the process tab? This is exactly what i have done and every time the CI build is triggered it takes the defaults set up by you in the template. Give it a try, i'll post you a screen shot if that helps? Jul 17, 2011 at 18:12
  • Mate, the 1st link i provided, is a microsoft walk through of how to edit the default build definition. The 2nd link gives you a list of all the possible MS build command line argument switches. Jul 17, 2011 at 18:13
  • 1
    isn't the second one for TFS builds? I have tried to change what you said and the build fail beacuse he doesn't know the switch
    – Clueless
    Jul 20, 2011 at 13:12
  • 2
    -1 because this answer is not helpful. As it stands, the information in the answer produces a build error because /priority is not a known MSBuild option (cf. the MSBuild command-line reference). But even if the option /p:Priority=High is used (as suggested by the other answer to the question), this has no effect whatsoever on the priority of the build, because here we are talking about the TFS build system priority, not the MSBuild system.
    – herzbube
    Jun 8, 2015 at 7:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.