Showing the changes to Build/Scripts (1 of 1 file). Show all
Unified · Split
| @@ -72,32 +72,21 @@ · 71 unmodified lines | ||
| 72 | 72 | <Import Project="Targets\Inline\TfsVersion.targets"/> |
| 73 | 73 | <Import Project="Targets\MSBuild Community Tasks\MSBuild.Community.Tasks.Targets"/> |
| 74 | 74 | <Import Project="Targets\MSBuild Extension Pack\MSBuild.ExtensionPack.tasks"/> |
| 75 | − | |
| 76 | − <PropertyGroup> | |
| 77 | 75 | |
| 78 | − <TfsUserName></TfsUserName> | |
| 79 | − | |
| 80 | − <TfsPassword></TfsPassword> | |
| 81 | − | |
| 82 | − <!-- Name of the project being built. --> | |
| 76 | + <PropertyGroup> | |
| 77 | + <!-- Name of the project being built. --> | |
| 83 | 78 | <ProjectName></ProjectName> |
| 84 | − | |
| 85 | − <!-- Solution of the project being built. --> | |
| 79 | + <!-- Solution of the project being built. --> | |
| 86 | 80 | <ProjectSolution></ProjectSolution> |
| 87 | − | |
| 88 | 81 | <!-- Name of the local build workspace. --> |
| 89 | 82 | <Workspace></Workspace> |
| 90 | − | |
| 91 | − <!-- URL of the Team Foundation Server. --> | |
| 83 | + <!-- URL of the Team Foundation Server. --> | |
| 92 | 84 | <TfsServer></TfsServer> |
| 93 | − | |
| 94 | − <!-- Root server folder of the project. --> | |
| 85 | + <!-- Root server folder of the project. --> | |
| 95 | 86 | <ServerFolder></ServerFolder> |
| 96 | − | |
| 97 | − <!-- Root local folder of the project. --> | |
| 87 | + <!-- Root local folder of the project. --> | |
| 98 | 88 | <LocalFolder></LocalFolder> |
| 99 | − | |
| 100 | − <!-- Source control label for the build. --> | |
| 89 | + <!-- Source control label for the build. --> | |
| 101 | 90 | <BuildLabel></BuildLabel> |
| 102 | 91 | <!-- Type of the build to compile. --> |
| 103 | 92 | <BuildFlavor></BuildFlavor> |
| @@ -109,10 +98,8 @@ · 5 unmodified lines | ||
| 109 | 98 | <BuildDeployFolder></BuildDeployFolder> |
| 110 | 99 | <!-- Setting for enabling user propmts. --> |
| 111 | 100 | <BuildInteractive></BuildInteractive> |
| 112 | − | |
| 113 | − | |
| 114 | 101 | <!-- File containing the build version. --> |
| 115 | − <VersionFile></VersionFile> | |
| 102 | + <VersionFile></VersionFile> | |
| 116 | 103 | <!-- Versioning scheme major number change type. --> |
| 117 | 104 | <VersionMajorChange></VersionMajorChange> |
| 118 | 105 | <!-- Versioning scheme minor number change type. --> |
| @@ -123,8 +110,10 @@ · 4 unmodified lines | ||
| 123 | 110 | <VersionRevisionChange></VersionRevisionChange> |
| 124 | 111 | <!-- Version of the source code to build. --> |
| 125 | 112 | <SourceVersion></SourceVersion> |
| 126 | − | |
| 127 | − | |
| 113 | + <!-- User name for Team Foundation Client. --> | |
| 114 | + <TfsUserName></TfsUserName> | |
| 115 | + <!-- Password for Team Foundation Client. --> | |
| 116 | + <TfsPassword></TfsPassword> | |
| 128 | 117 | <!-- Paths to Team Foundation Client. --> |
| 129 | 118 | <TfsClient></TfsClient> |
| 130 | 119 | <!-- Path to Visual Studio IDE. --> |
| @@ -133,19 +122,14 @@ · 2 unmodified lines | ||
| 133 | 122 | <MSTest></MSTest> |
| 134 | 123 | <!-- Path to Sandcastle Builder. --> |
| 135 | 124 | <SandcastleBuilder></SandcastleBuilder> |
| 136 | − | |
| 137 | − | |
| 138 | 125 | <!-- Forces a build regardless of new changes since last build. --> |
| 139 | 126 | <ForceBuild></ForceBuild> |
| 140 | 127 | <!-- Skips the versioning process and just executes build steps. --> |
| 141 | − <SkipVersioning></SkipVersioning> | |
| 142 | − | |
| 143 | − <!--Executes build without running unit tests when true.--> | |
| 144 | − <SkipUnitTest>True</SkipUnitTest> | |
| 145 | − | |
| 128 | + <SkipVersioning></SkipVersioning> | |
| 129 | + <!--Executes build without running unit tests when true.--> | |
| 130 | + <SkipUnitTest>True</SkipUnitTest> | |
| 146 | 131 | <!-- Name of binaries archive file. --> |
| 147 | 132 | <BinariesArchiveFileName></BinariesArchiveFileName> |
| 148 | − | |
| 149 | 133 | <!-- Name of installs archive file. --> |
| 150 | 134 | <InstallsArchiveFileName></InstallsArchiveFileName> |
| 151 | 135 | <!-- Working directory for creating binaries archive file. --> |
| @@ -153,7 +137,7 @@ · 1 unmodified line | ||
| 153 | 137 | <!-- Working directory for creating installs archive file. --> |
| 154 | 138 | <InstallsArchiveWorkingDirectory></InstallsArchiveWorkingDirectory> |
| 155 | 139 | </PropertyGroup> |
| 156 | − | |
| 140 | + | |
| 157 | 141 | <PropertyGroup> |
| 158 | 142 | <!-- |
| 159 | 143 | InitializeBuild |
| @@ -202,7 +186,6 @@ · 42 unmodified lines | ||
| 202 | 186 | CorePrepareSettings; |
| 203 | 187 | AfterPrepareSettings; |
| 204 | 188 | </PrepareSettingsDependsOn> |
| 205 | − | |
| 206 | 189 | <CreateWorkspaceDependsOn> |
| 207 | 190 | BeforeCreateWorkspace; |
| 208 | 191 | CoreCreateWorkspace; |
| @@ -257,33 +240,27 @@ · 48 unmodified lines | ||
| 257 | 240 | AfterDeleteWorkspace; |
| 258 | 241 | </DeleteWorkspaceDependsOn> |
| 259 | 242 | </PropertyGroup> |
| 260 | − | |
| 243 | + | |
| 261 | 244 | <ItemGroup> |
| 262 | 245 | <!-- List of projects to build. --> |
| 263 | 246 | <ProjectsToBuild Include="Nothing" Exclude="Nothing"/> |
| 264 | − | |
| 265 | 247 | <!-- List of installs to build. --> |
| 266 | 248 | <InstallsToBuild Include="Nothing" Exclude="Nothing"/> |
| 267 | − | |
| 268 | 249 | <!-- List of files to be versioned. --> |
| 269 | 250 | <FilesToVersion Include="Nothing" Exclude="Nothing"> |
| 270 | 251 | <VersionRegex>(?'BeforeVersion')(?'CoreVersion')(?'AfterVersion')</VersionRegex> |
| 271 | 252 | <VersionPrecision>4</VersionPrecision> |
| 272 | 253 | </FilesToVersion> |
| 273 | − | |
| 274 | 254 | <!-- List of unit test assemblies. --> |
| 275 | 255 | <UnitTestAssemblies Include="Nothing" Exclude="Nothing"/> |
| 276 | − | |
| 277 | 256 | <!-- List of binaries to archive. --> |
| 278 | 257 | <BinariesToArchive Include="Nothing" Exclude="Nothing"/> |
| 279 | − | |
| 280 | 258 | <!-- List of installs to archive. --> |
| 281 | 259 | <InstallsToArchive Include="Nothing" Exclude="Nothing"/> |
| 282 | − | |
| 283 | 260 | <!-- Destinations of archive files (*.zip). --> |
| 284 | 261 | <ArchiveDestinations Include="Nothing" Exclude="Nothing"/> |
| 285 | 262 | </ItemGroup> |
| 286 | − | |
| 263 | + | |
| 287 | 264 | <Target Name="All"> |
| 288 | 265 | <!-- Entry point for the build. --> |
| 289 | 266 | <CallTarget Targets="InitializeBuild"/> |
| @@ -292,42 +269,30 @@ · 2 unmodified lines | ||
| 292 | 269 | <Beep/> |
| 293 | 270 | <OnError ExecuteTargets="HandleBuildFailure"/> |
| 294 | 271 | </Target> |
| 295 | − | |
| 272 | + | |
| 296 | 273 | <Target Name="InitializeBuild" DependsOnTargets="$(InitializeBuildDependsOn)"/> |
| 297 | − | |
| 298 | 274 | <Target Name="CompileBuild" DependsOnTargets="$(CompileBuildDependsOn)"/> |
| 299 | − | |
| 300 | 275 | <Target Name="FinalizeBuild" DependsOnTargets="$(FinalizeBuildDependsOn)"/> |
| 301 | − | |
| 302 | 276 | <Target Name="PrepareSettings" DependsOnTargets="$(PrepareSettingsDependsOn)"/> |
| 303 | − | |
| 304 | 277 | <Target Name="CheckEnvironment" DependsOnTargets="$(CheckEnvironmentDependsOn)"/> |
| 305 | − | |
| 306 | 278 | <Target Name="CreateWorkspace" DependsOnTargets="$(CreateWorkspaceDependsOn)"/> |
| 307 | − | |
| 308 | 279 | <Target Name="PopulateWorkspace" DependsOnTargets="$(PopulateWorkspaceDependsOn)"/> |
| 309 | − | |
| 310 | 280 | <Target Name="VersionSource" DependsOnTargets="$(VersionSourceDependsOn)" Condition="'$(ForceBuild)' == 'true'"/> |
| 311 | − | |
| 312 | 281 | <Target Name="BuildProjects" DependsOnTargets="$(BuildProjectsDependsOn)" Condition="'$(ForceBuild)' == 'true'"/> |
| 313 | − | |
| 314 | 282 | <Target Name="ExecuteUnitTests" DependsOnTargets="$(ExecuteUnitTestsDependsOn)" Condition="'$(ForceBuild)' == 'true' And '$(SkipUnitTest)' == 'false'"/> |
| 315 | − | |
| 316 | 283 | <Target Name="LabelBuild" DependsOnTargets="$(LabelBuildDependsOn)" Condition="'$(ForceBuild)' == 'true'"/> |
| 317 | − | |
| 318 | 284 | <Target Name="CleanBuild" DependsOnTargets="$(CleanBuildDependsOn)" Condition="'$(ForceBuild)' == 'true'"/> |
| 319 | − | |
| 320 | 285 | <Target Name="DeployBuild" DependsOnTargets="$(DeployBuildDependsOn)" Condition="'$(ForceBuild)' == 'true'"/> |
| 321 | − | |
| 322 | 286 | <Target Name="DeleteWorkspace" DependsOnTargets="$(DeleteWorkspaceDependsOn)"/> |
| 323 | − | |
| 324 | 287 | <Target Name="BeforePrepareSettings"/> |
| 325 | − | |
| 288 | + | |
| 326 | 289 | <Target Name="CorePrepareSettings"> |
| 327 | 290 | <!-- Assign default values to unassigned properties. --> |
| 328 | 291 | <Message Text="Preparing settings for build..."/> |
| 292 | + | |
| 329 | 293 | <Error Condition="'$(ProjectName)' == ''" Text="ProjectName property must be set."/> |
| 330 | 294 | <Error Condition="'$(TfsServer)' == ''" Text="TfsServer property must be set."/> |
| 295 | + | |
| 331 | 296 | <PropertyGroup> |
| 332 | 297 | <ServerFolder Condition="'$(ServerFolder)' == ''">$/$(ProjectName)/Main</ServerFolder> |
| 333 | 298 | <LocalFolder Condition="'$(LocalFolder)' == ''">$([System.IO.Path]::GetFullPath('$(TEMP)\MSBuild\$(ProjectName)'))</LocalFolder> |
| @@ -337,12 +302,12 @@ · 3 unmodified lines | ||
| 337 | 302 | <BuildInteractive Condition="'$(BuildInteractive)' == ''">true</BuildInteractive> |
| 338 | 303 | <VersionFile Condition="'$(VersionFile)' == ''">$(LocalFolder)\Build\Scripts\$(ProjectName).version</VersionFile> |
| 339 | 304 | <SourceVersion Condition="'$(SourceVersion)' == ''">T</SourceVersion> |
| 340 | − <TfsClient Condition="'$(TfsClient)' == ''">$(VS120COMNTOOLS)\..\IDE\tf.exe</TfsClient> | |
| 341 | − <VisualStudio Condition="'$(VisualStudio)' == ''">$(VS120COMNTOOLS)\..\IDE\devenv.com</VisualStudio> | |
| 342 | − <MSTest Condition="'$(MSTest)' == ''">$(VS120COMNTOOLS)\..\IDE\mstest.exe</MSTest> | |
| 305 | + <TfsClient Condition="'$(TfsClient)' == ''">$(VS110COMNTOOLS)\..\IDE\tf.exe</TfsClient> | |
| 306 | + <VisualStudio Condition="'$(VisualStudio)' == ''">$(VS110COMNTOOLS)\..\IDE\devenv.com</VisualStudio> | |
| 307 | + <MSTest Condition="'$(MSTest)' == ''">$(VS110COMNTOOLS)\..\IDE\mstest.exe</MSTest> | |
| 343 | 308 | <SandcastleBuilder Condition="'$(SandcastleBuilder)' == ''">$(SHFBROOT)\SandcastleBuilderGUI.exe</SandcastleBuilder> |
| 344 | 309 | <ForceBuild Condition="'$(ForceBuild)' == ''">false</ForceBuild> |
| 345 | − <ForceBuild Condition="'$(SourceVersion)' != 'T'">true</ForceBuild> | |
| 310 | + <ForceBuild Condition="'$(SourceVersion)' != 'T'">true</ForceBuild> | |
| 346 | 311 | <SkipVersioning Condition="'$(SkipVersioning)' == ''">false</SkipVersioning> |
| 347 | 312 | <BinariesArchiveFileName Condition="'$(BinariesArchiveFileName)' == ''">$(LocalFolder)\$(ProjectName).Binaries.zip</BinariesArchiveFileName> |
| 348 | 313 | <InstallsArchiveFileName Condition="'$(InstallsArchiveFileName)' == ''">$(LocalFolder)\$(ProjectName).Installs.zip</InstallsArchiveFileName> |
| @@ -350,54 +315,55 @@ · 1 unmodified line | ||
| 350 | 315 | <InstallsArchiveWorkingDirectory Condition="'$(InstallsArchiveWorkingDirectory)' == ''">$(LocalFolder)\Archives\Installs</InstallsArchiveWorkingDirectory> |
| 351 | 316 | </PropertyGroup> |
| 352 | 317 | </Target> |
| 353 | − | |
| 318 | + | |
| 354 | 319 | <Target Name="AfterPrepareSettings"/> |
| 355 | − | |
| 356 | 320 | <Target Name="BeforeCheckEnvironment"/> |
| 357 | − | |
| 321 | + | |
| 358 | 322 | <Target Name="CoreCheckEnvironment"> |
| 359 | 323 | <!-- Ensure that all required tools are installed. --> |
| 360 | 324 | <Message Text="Checking for required application..."/> |
| 325 | + | |
| 361 | 326 | <Error Condition="'$(TfsClient)' != '' And !Exists('$(TfsClient)')" Text="TFS Client is not installed."/> |
| 362 | 327 | <Error Condition="'$(VisualStudio)' != '' And !Exists('$(VisualStudio)')" Text="Visual Studio is not installed."/> |
| 363 | 328 | <Error Condition="'$(MSTest)' != '' And !Exists('$(MSTest)')" Text="Unit testing tool is not installed."/> |
| 364 | 329 | <Error Condition="'$(SandcastleBuilder)' != '' And !Exists('$(SandcastleBuilder)')" Text="Sandcastle Builder is not installed."/> |
| 365 | 330 | </Target> |
| 366 | − | |
| 331 | + | |
| 367 | 332 | <Target Name="AfterCheckEnvironment"/> |
| 368 | − | |
| 369 | 333 | <Target Name="BeforeCreateWorkspace"/> |
| 370 | − | |
| 334 | + | |
| 371 | 335 | <Target Name="CoreCreateWorkspace"> |
| 372 | 336 | <!-- Create a temporary workspace for the build. --> |
| 373 | 337 | <Message Text="Creating temporary workspace..."/> |
| 338 | + | |
| 339 | + | |
| 374 | 340 | <PropertyGroup> |
| 375 | 341 | <Workspace Condition="'$(Workspace)' == ''">$(COMPUTERNAME)_$(ProjectName)</Workspace> |
| 376 | 342 | </PropertyGroup> |
| 343 | + | |
| 377 | 344 | <RemoveDir Directories="$(LocalFolder)" Condition="Exists('$(LocalFolder)')"/> |
| 378 | − <MakeDir Directories="$(LocalFolder)"/> | |
| 345 | + <MakeDir Directories="$(LocalFolder)"/> | |
| 379 | 346 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 workspace /new /server:$(TfsServer) /noprompt %22$(Workspace)%22" WorkingDirectory="$(LocalFolder)"/> |
| 380 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workspace /new /server:$(TfsServer) /noprompt %22$(Workspace)%22 /login:$(TfsUserName),$(TfsPassword)" WorkingDirectory="$(LocalFolder)"/> | |
| 347 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workspace /new /server:$(TfsServer) /noprompt %22$(Workspace)%22 /login:$(TfsUserName),$(TfsPassword)" WorkingDirectory="$(LocalFolder)"/> | |
| 381 | 348 | <Exec Condition="'$(TFSUserName)' == ''" Command="%22$(TfsClient)%22 workfold /unmap /server:$(TfsServer) /workspace:%22$(Workspace)%22 $/"/> |
| 382 | − <Exec Condition="'$(TFSUserName)' != ''" Command="%22$(TfsClient)%22 workfold /unmap /server:$(TfsServer) /workspace:%22$(Workspace)%22 $/ /login:$(TfsUserName),$(TfsPassword)"/> | |
| 349 | + <Exec Condition="'$(TFSUserName)' != ''" Command="%22$(TfsClient)%22 workfold /unmap /server:$(TfsServer) /workspace:%22$(Workspace)%22 $/ /login:$(TfsUserName),$(TfsPassword)"/> | |
| 383 | 350 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 workfold /map /server:$(TfsServer) /workspace:%22$(Workspace)%22 %22$(ServerFolder)%22 %22$(LocalFolder)%22"/> |
| 384 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workfold /map /server:$(TfsServer) /workspace:%22$(Workspace)%22 %22$(ServerFolder)%22 %22$(LocalFolder)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 351 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workfold /map /server:$(TfsServer) /workspace:%22$(Workspace)%22 %22$(ServerFolder)%22 %22$(LocalFolder)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 385 | 352 | </Target> |
| 386 | 353 | |
| 387 | 354 | <Target Name="AfterCreateWorkspace"/> |
| 388 | − | |
| 389 | 355 | <Target Name="BeforePopulateWorkspace"/> |
| 390 | − | |
| 356 | + | |
| 391 | 357 | <Target Name="CorePopulateWorkspace"> |
| 392 | 358 | <!-- Get source code for the specified version. --> |
| 393 | − <Message Text="Getting source code..."/> | |
| 359 | + <Message Text="Getting source code..."/> | |
| 394 | 360 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 get %22$(LocalFolder)%22 /version:$(SourceVersion) /force /recursive /noprompt"/> |
| 395 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 get %22$(LocalFolder)%22 /version:$(SourceVersion) /force /recursive /noprompt /login:$(TfsUserName),$(TfsPassword)"/> | |
| 361 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 get %22$(LocalFolder)%22 /version:$(SourceVersion) /force /recursive /noprompt /login:$(TfsUserName),$(TfsPassword)"/> | |
| 396 | 362 | </Target> |
| 397 | − | |
| 363 | + | |
| 398 | 364 | <Target Name="CheckForChanges" Condition="'$(ForceBuild)' != 'true'"> |
| 399 | 365 | <!-- Check for new changes since the last build. --> |
| 400 | − <Message Text="Checking for changes..."/> | |
| 366 | + <Message Text="Checking for changes..."/> | |
| 401 | 367 | <ReadLinesFromFile File="$(VersionFile)"> |
| 402 | 368 | <Output TaskParameter="Lines" ItemName="VersionNumber"/> |
| 403 | 369 | </ReadLinesFromFile> |
| @@ -409,18 +375,17 @@ · 5 unmodified lines | ||
| 409 | 375 | </PropertyGroup> |
| 410 | 376 | <Message Text="Build is skipped - No new changes." Condition="'$(ForceBuild)' != 'true'"/> |
| 411 | 377 | </Target> |
| 412 | − | |
| 378 | + | |
| 413 | 379 | <Target Name="AfterPopulateWorkspace"/> |
| 414 | − | |
| 415 | 380 | <Target Name="BeforeVersionSource"/> |
| 416 | − | |
| 381 | + | |
| 417 | 382 | <Target Name="CoreVersionSource" Condition="'$(SourceVersion)' == 'T' And '@(FilesToVersion)' != '' And '$(SkipVersioning)' != 'true'"> |
| 418 | 383 | <!-- Update version number of the source code. --> |
| 419 | 384 | <Message Text="Versioning source code..."/> |
| 420 | 385 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 checkout /noprompt %22$(VersionFile)%22"/> |
| 421 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 checkout /noprompt %22$(VersionFile)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 386 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 checkout /noprompt %22$(VersionFile)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 422 | 387 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 checkout /noprompt %22%(FilesToVersion.FullPath)%22"/> |
| 423 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 checkout /noprompt %22%(FilesToVersion.FullPath)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 388 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 checkout /noprompt %22%(FilesToVersion.FullPath)%22 /login:$(TfsUserName),$(TfsPassword)"/> | |
| 424 | 389 | <Version VersionFile="$(VersionFile)" Major="$(VersionMajorChange)" Minor="$(VersionMinorChange)" BuildType="$(VersionBuildChange)" RevisionType="$(VersionRevisionChange)"> |
| 425 | 390 | <Output TaskParameter="Major" PropertyName="Major"/> |
| 426 | 391 | <Output TaskParameter="Minor" PropertyName="Minor"/> |
| @@ -435,18 +400,19 @@ · 8 unmodified lines | ||
| 435 | 400 | <BuildLabel Condition="'$(BuildLabel)' == ''">$(ProjectName)_v$(Major).$(Minor).$(Build).$(Revision)</BuildLabel> |
| 436 | 401 | </PropertyGroup> |
| 437 | 402 | </Target> |
| 438 | − | |
| 403 | + | |
| 439 | 404 | <Target Name="AfterVersionSource"/> |
| 440 | − | |
| 441 | 405 | <Target Name="BeforeBuildProjects"/> |
| 442 | − | |
| 406 | + | |
| 443 | 407 | <Target Name="CoreBuildProjects"> |
| 444 | 408 | <!-- Build all of the specified projects. --> |
| 445 | − <Message Text="Compiling projects..."/> | |
| 409 | + <Message Text="Compiling projects..."/> | |
| 446 | 410 | <MSBuild Projects="@(ProjectsToBuild)" Properties="Configuration=$(BuildFlavor);Platform=$(BuildTarget);%(ProjectsToBuild.Properties)"/> |
| 411 | + | |
| 447 | 412 | <!-- Build all of the specified installs. --> |
| 448 | 413 | <Message Text="Compiling installs..."/> |
| 449 | 414 | <Exec Command="%22$(VisualStudio)%22 %22$(ProjectSolution)%22 /Project %22%(InstallsToBuild.FullPath)%22 /Build %22$(BuildFlavor)|$(BuildTarget)%22" Condition="'$(ProjectSolution)' != '' And '@(InstallsToBuild)' != ''"/> |
| 415 | + | |
| 450 | 416 | <!-- Create list of files to be deleted from build output. --> |
| 451 | 417 | <ItemGroup> |
| 452 | 418 | <FilesToDelete Include="$(BuildOutputFolder)\**\setup.exe"/> |
| @@ -455,43 +421,39 @@ · 2 unmodified lines | ||
| 455 | 421 | <FilesToDelete Include="$(BuildOutputFolder)\**\*.vshost.exe.manifest"/> |
| 456 | 422 | </ItemGroup> |
| 457 | 423 | </Target> |
| 458 | − | |
| 424 | + | |
| 459 | 425 | <Target Name="AfterBuildProjects"/> |
| 460 | − | |
| 461 | 426 | <Target Name="BeforeExecuteUnitTests"/> |
| 462 | − | |
| 427 | + | |
| 463 | 428 | <Target Name="CoreExecuteUnitTests" Condition="'@(UnitTestAssemblies)' != ''"> |
| 464 | 429 | <!-- Execute tests in unit test assemblies. --> |
| 465 | 430 | <Message Text="Executing unit tests..."/> |
| 466 | 431 | <Exec Command="%22$(MSTest)%22 /testcontainer:%22%(UnitTestAssemblies.FullPath)%22" WorkingDirectory="%(UnitTestAssemblies.RootDir)%(UnitTestAssemblies.Directory)"/> |
| 467 | 432 | </Target> |
| 468 | − | |
| 433 | + | |
| 469 | 434 | <Target Name="AfterExecuteUnitTests"/> |
| 470 | − | |
| 471 | 435 | <Target Name="BeforeLabelBuild"/> |
| 472 | − | |
| 436 | + | |
| 473 | 437 | <Target Name="CoreLabelBuild" Condition="'$(BuildLabel)' != '' And '$(SkipVersioning)' != 'true'"> |
| 474 | 438 | <!-- Apply label for the current build. --> |
| 475 | 439 | <Message Text="Labeling build $(BuildLabel)..."/> |
| 476 | 440 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 label %22$(BuildLabel)%22 %22$(LocalFolder)%22 /comment:%22Label applied for build $(BuildLabel).%22 /recursive"/> |
| 477 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 label %22$(BuildLabel)%22 %22$(LocalFolder)%22 /comment:%22Label applied for build $(BuildLabel).%22 /recursive /login:$(TfsUserName),$(TfsPassword)"/> | |
| 441 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 label %22$(BuildLabel)%22 %22$(LocalFolder)%22 /comment:%22Label applied for build $(BuildLabel).%22 /recursive /login:$(TfsUserName),$(TfsPassword)"/> | |
| 478 | 442 | </Target> |
| 479 | 443 | |
| 480 | 444 | <Target Name="AfterLabelBuild"/> |
| 481 | − | |
| 482 | 445 | <Target Name="BeforeCleanBuild"/> |
| 483 | − | |
| 484 | − <Target Name="CoreCleanBuild"> | |
| 446 | + | |
| 447 | + <Target Name="CoreCleanBuild"> | |
| 485 | 448 | <!-- Clean output of the current build. --> |
| 486 | 449 | <Message Text="Cleaning build output..."/> |
| 487 | 450 | <Delete Files="@(FilesToDelete)" ContinueOnError="true"/> |
| 488 | 451 | </Target> |
| 489 | − | |
| 490 | − <Target Name="AfterCleanBuild"/> | |
| 491 | 452 | |
| 453 | + <Target Name="AfterCleanBuild"/> | |
| 492 | 454 | <Target Name="BeforeDeployBuild"/> |
| 493 | − | |
| 494 | − <Target Name="CoreDeployBuild" Condition="'$(BuildOutputFolder)' != '' And '$(BuildDeployFolder)' != ''"> | |
| 455 | + | |
| 456 | + <Target Name="CoreDeployBuild" Condition="'$(BuildOutputFolder)' != '' And '$(BuildDeployFolder)' != ''"> | |
| 495 | 457 | <!-- Copy build content to the deploy folder. --> |
| 496 | 458 | <Message Text="Deploying build content..."/> |
| 497 | 459 | <ItemGroup> |
| @@ -502,7 +464,7 @@ · 4 unmodified lines | ||
| 502 | 464 | <Copy SourceFiles="@(FilesToDeploy)" DestinationFolder="$(BuildDeployFolder)\%(FilesToDeploy.RecursiveDir)"/> |
| 503 | 465 | <CallTarget Targets="ArchiveBuildOutput"/> |
| 504 | 466 | </Target> |
| 505 | − | |
| 467 | + | |
| 506 | 468 | <Target Name="ArchiveBuildOutput" Condition="'@(BinariesToArchive)' != '' Or '@(InstallsToArchive)' != ''"> |
| 507 | 469 | <!-- Create specified archives of build content. --> |
| 508 | 470 | <Message Text="Archiving build content..."/> |
| @@ -521,30 +483,29 @@ · 12 unmodified lines | ||
| 521 | 483 | </ItemGroup> |
| 522 | 484 | <Copy SourceFiles="@(Archives)" DestinationFolder="%(ArchiveDestinations.FullPath)" ContinueOnError="true"/> |
| 523 | 485 | </Target> |
| 524 | − | |
| 525 | − <Target Name="AfterDeployBuild"/> | |
| 526 | 486 | |
| 487 | + <Target Name="AfterDeployBuild"/> | |
| 527 | 488 | <Target Name="BeforeDeleteWorkspace"/> |
| 528 | 489 | |
| 529 | 490 | <Target Name="CoreDeleteWorkspace"> |
| 530 | 491 | <!-- Checkin all of the pending changes. --> |
| 531 | 492 | <Message Text="Checking in pending changes..." Condition="'$(SkipVersioning)' != 'true'" /> |
| 532 | 493 | <Exec Condition="'$(TfsUserName)' == '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 checkin /comment:%22$(ProjectName): Version change for build $(BuildLabel).%22 /recursive /noprompt %22$(LocalFolder)%22" ContinueOnError="true" /> |
| 533 | − <Exec Condition="'$(TfsUserName)' != '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 checkin /comment:%22$(ProjectName): Version change for build $(BuildLabel).%22 /recursive /noprompt %22$(LocalFolder)%22 /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 494 | + <Exec Condition="'$(TfsUserName)' != '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 checkin /comment:%22$(ProjectName): Version change for build $(BuildLabel).%22 /recursive /noprompt %22$(LocalFolder)%22 /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 534 | 495 | <!-- Delete the temporary build workpsace. --> |
| 535 | 496 | <Message Text="Deleting temporary workspace..."/> |
| 536 | 497 | <Exec Condition="'$(TfsUserName)' == ''" Command="%22$(TfsClient)%22 workspace /delete /server:$(TfsServer) %22$(Workspace)%22" ContinueOnError="true"/> |
| 537 | − <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workspace /delete /server:$(TfsServer) %22$(Workspace)%22 /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 498 | + <Exec Condition="'$(TfsUserName)' != ''" Command="%22$(TfsClient)%22 workspace /delete /server:$(TfsServer) %22$(Workspace)%22 /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 538 | 499 | </Target> |
| 500 | + | |
| 539 | 501 | <Target Name="AfterDeleteWorkspace"/> |
| 540 | 502 | |
| 541 | 503 | <Target Name="HandleBuildFailure"> |
| 542 | 504 | <!-- Handle any unexpected build errors. --> |
| 543 | 505 | <Message Text="Undoing pending changes..." Condition="'$(SkipVersioning)' != 'true'" /> |
| 544 | 506 | <Exec Condition="'$(TfsUserName)' == '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 undo %22$(LocalFolder)%22 /recursive /noprompt" ContinueOnError="true"/> |
| 545 | − <Exec Condition="'$(TfsUserName)' != '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 undo %22$(LocalFolder)%22 /recursive /noprompt /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 507 | + <Exec Condition="'$(TfsUserName)' != '' and '$(SkipVersioning)' != 'true'" Command="%22$(TfsClient)%22 undo %22$(LocalFolder)%22 /recursive /noprompt /login:$(TfsUserName),$(TfsPassword)" ContinueOnError="true"/> | |
| 546 | 508 | <CallTarget Targets="DeleteWorkspace"/> |
| 547 | 509 | <Beep Duration="2000"/> |
| 548 | 510 | </Target> |
| 549 | − | |
| 550 | 511 | </Project> |