Stop Command (Team Foundation Build)
The stop command stops a currently running Team Foundation Build build definition.
Required Permissions
To use the stop command, you must have the Team Foundation Server Administer a build security permission set to Allow. For more information, see Team Foundation Server Permissions.
Note
Even if you are logged on with administrative credentials, you must open an elevated Command Prompt to perform this function on a server that is running Windows Server 2008. To open an elevated Command Prompt, click Start, right-click Command Prompt, and click Run as Administrator. For more information, see the Microsoft Web site.
TFSBuild stop [/noprompt] [/silent] /server:teamFoundationServer /builddefinition:definitionSpec buildNumbers…
TFSBuild stop [/noprompt] [/silent] /server:teamFoundationServer buildUris
TFSBuild stop [/noprompt] [/silent] teamFounadtionServer teamProject buildNumbers
Parameters
Argument |
Description |
---|---|
teamfoundationserver |
The Team Foundation server URL. |
teamProject |
The team project name for which this build exists. |
buildNumbers |
The build or builds that must be stopped. If the build number has spaces, the spaces must be within quotation marks, for example "myBuild 123." |
buildUris |
The list of build URIs that specify the build definitions to be stopped. |
definitionSpec |
The specification of the build definition or definitions to be stopped. |
Option |
Description |
---|---|
/noprompt |
Do not prompt when stopping a build. |
/silent |
Do not write output to the console while stopping the build or builds. |
/server |
Specifies the Team Foundation server. |
/builddefinition |
Specifies the build definitions that are to be stopped. |
Example
The following example stops running build number Nightly.025, which is in the AdventureWorks team project on server01.
>TFSBuild stop http://server01:8080 AdventureWorks Nightly.025
The following example stops running build named Nightly, which is associated with the Nightly.20130.0 definitionspec.
>TFSBuild stop /server::http://server01:8080 /builddefinition:\teamproject\Nightly Nightly.20130.0
The following example stops running two builds defined by the build URIs of "vstfs:///Nightly/Nightly/1" and "vstfs:///Nightly/Nightly/2" on server01.
> TFSBuild stop /server::http://server01:8080 vstfs:///Nightly/Nightly/1 vstfs:///Nightly/Nightly/2
See Also
Tasks
How to: Stop a Build (Command-Line)
How to: Create a Build Definition
Other Resources
Team Foundation Build Commands