diff options
author | Matt Mitchell <mmitche@microsoft.com> | 2015-03-06 03:34:36 +0300 |
---|---|---|
committer | Matt Mitchell <mmitche@microsoft.com> | 2015-03-06 03:34:36 +0300 |
commit | c65330643af96e7bffa0b92848dd53646b07f615 (patch) | |
tree | d7a97440638d9574dcd1342c319c2aaeb68bce41 /build.proj | |
parent | bea6b2d293277f8850d8c34006098df36adbfa9c (diff) | |
parent | 1223f8763e7839f8a1b8a07cea88ba1bb7bdf0af (diff) |
Merge branch 'master' into coveralls-upload
Conflicts:
build.proj
Diffstat (limited to 'build.proj')
-rw-r--r-- | build.proj | 74 |
1 files changed, 13 insertions, 61 deletions
diff --git a/build.proj b/build.proj index 574b4a773d..00abeaaaea 100644 --- a/build.proj +++ b/build.proj @@ -1,76 +1,29 @@ <?xml version="1.0" encoding="utf-8"?> -<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project ToolsVersion="12.0" DefaultTargets="BuildAndTest" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Import Project="dir.props" /> - <!-- Inline task to bootstrap the build to enable downloading nuget.exe --> - <UsingTask TaskName="DownloadFile" TaskFactory="CodeTaskFactory" AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v12.0.dll"> - <ParameterGroup> - <Address ParameterType="System.String" Required="true"/> - <FileName ParameterType="System.String" Required="true" /> - </ParameterGroup> - <Task> - <Reference Include="System" /> - <Code Type="Fragment" Language="cs"> - <![CDATA[ - var directory = System.IO.Path.GetDirectoryName(FileName); - System.IO.Directory.CreateDirectory(directory); - var client = new System.Net.WebClient(); - client.Proxy = System.Net.WebRequest.DefaultWebProxy; - client.Proxy.Credentials = System.Net.CredentialCache.DefaultCredentials; - client.DownloadFile(Address, FileName); - ]]> - </Code> - </Task> - </UsingTask> - - <Target Name="_RestoreBuildTools" - BeforeTargets="BuildAllProjects" - Inputs="$(BuildToolsTargetInputs)" - Outputs="$(BuildToolsTargetOutputs)" - > - <Message Importance="High" Text="Restoring build tools..." /> - - <!-- Download latest nuget.exe --> - <DownloadFile - Condition="!Exists($(NuGetToolPath))" - Address="http://nuget.org/nuget.exe" - FileName="$(NuGetToolPath)" /> - - <!-- Restore build tools --> - <Exec - StandardOutputImportance="Low" - Command=""$(NuGetToolPath)" install " $(SourceDir).nuget\packages.config " -o " $(PackagesDir) " $(NuGetConfigCommandLine)" /> - - <Touch Files="$(BuildToolsInstallSemaphore)" AlwaysCreate="true" /> - </Target> - <ItemGroup> <Project Include="src\dirs.proj" /> </ItemGroup> + <Import Project="dir.targets" /> + <Import Project="dir.traversal.targets" /> <!-- Override clean from dir.traversal.targets and just remove the full BinDir --> <Target Name="Clean"> - <RemoveDir Directories="$(BinDir);$(PackagesDir)" /> + <RemoveDir Directories="$(BinDir)" /> </Target> - + <Target Name="GenerateCoverageReport" - AfterTargets="Build" - Inputs="$(CoverageReportDir)\*.coverage.xml" - Outputs="$(CoverageReportDir)*.*" - Condition="$(_CoverageEnabled)"> - - <PropertyGroup> - <ReportGeneratorVersion>2.0.4.0</ReportGeneratorVersion> - <ReportGeneratorCommandLine>$(PackagesDir)ReportGenerator.$(ReportGeneratorVersion)\ReportGenerator.exe</ReportGeneratorCommandLine> - <ReportGeneratorOptions>-reports:$(CoverageReportDir)\*.coverage.xml -targetdir:$(CoverageReportDir) -reporttypes:Html</ReportGeneratorOptions> - </PropertyGroup> - - <Exec - Command="$(ReportGeneratorCommandLine) $(ReportGeneratorOptions)" - ContinueOnError="ErrorAndContinue" /> - + AfterTargets="Test" + Inputs="$(CoverageReportDir)\*.coverage.xml" + Outputs="$(CoverageReportDir)index.htm" + Condition="$(_CoverageEnabled)"> + + <Exec Command="$(CoverageReportGeneratorCommandLine) -reports:$(CoverageReportDir)\*.coverage.xml" + ContinueOnError="ErrorAndContinue" /> + <PropertyGroup> <CoverallsUploaderVersion>1.1.86</CoverallsUploaderVersion> <CoverallsUploaderCommandLine>$(PackagesDir)coveralls.io.$(CoverallsUploaderVersion)\tools\coveralls.net.exe</CoverallsUploaderCommandLine> @@ -81,7 +34,6 @@ Command="$(CoverallsUploaderCommandLine) $(CoverallsUploaderOptions)" ContinueOnError="ErrorAndContinue" Condition="'$(UploadCoverallsData)'" /> - </Target> </Project>
\ No newline at end of file |