Skip to content

Commit

Permalink
refactoring props (#1510)
Browse files Browse the repository at this point in the history
* refactoring props

* remove AddXmlLanguage from Test projects
  • Loading branch information
TimothyMothra authored Dec 19, 2019
1 parent 77c4bca commit e821aab
Show file tree
Hide file tree
Showing 38 changed files with 25 additions and 110 deletions.
2 changes: 1 addition & 1 deletion .targets/AddXmlLanguage.targets
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
}
else
{
Log.LogError("InjectXmlLanguage: Assembly XML Doc file not found in bin folder.");
Log.LogError("InjectXmlLanguage: Assembly XML Doc file not found in bin folder.");
}
]]></Code>
</Task>
Expand Down
1 change: 0 additions & 1 deletion BASE/Common.targets
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<Import Project="Signing.targets" />
<Import Project="$(TargetsRoot)\AddXmlLanguage.targets" />

</Project>
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.props'))\Common.props"/>
<Import Project="$(SourceRoot)\Common.props"/>

<Import Project="$(TargetsRoot)\AddXmlLanguage.targets" />

<PropertyGroup>
<!--Removing the SRC folder from the output directory-->
<CorePath>$(RelativeOutputPathBase.Substring(4))</CorePath>
<OutputPath>$(BinRoot)\$(Configuration)\$(CorePath)</OutputPath>
<OutputPath>$([System.IO.Path]::GetFullPath( $(OutputPath) ))\</OutputPath>
</PropertyGroup>

<PropertyGroup>
<RootNamespace>Microsoft.ApplicationInsights</RootNamespace>
<AssemblyName>$(RootNamespace)</AssemblyName>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
<Project ToolsVersion="15.0" Sdk="Microsoft.NET.Sdk">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildProjectDirectory), 'Product.props'))\Product.props" />
<Import Project="$(SourceRoot)\Product.props" />
<Import Project="$(PropsRoot)\_Nupkg.props" />

<PropertyGroup>
<RootNamespace>Microsoft.ApplicationInsights</RootNamespace>
<AssemblyName>Microsoft.ApplicationInsights</AssemblyName>
<TargetFrameworks>net45;net46;netstandard1.3;netstandard2.0</TargetFrameworks>
<TargetFrameworks Condition="$(OS) != 'Windows_NT'">netstandard1.3;netstandard2.0</TargetFrameworks>
</PropertyGroup>
Expand Down Expand Up @@ -88,5 +90,5 @@

<Import Project="..\Common\Common\Common.projitems" Label="Shared" />

<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<Import Project="$(SourceRoot)\Common.targets" />
</Project>
15 changes: 0 additions & 15 deletions BASE/src/ServerTelemetryChannel/Product.props

This file was deleted.

8 changes: 5 additions & 3 deletions BASE/src/ServerTelemetryChannel/TelemetryChannel.csproj
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
<Project ToolsVersion="15.0" Sdk="Microsoft.NET.Sdk">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildProjectDirectory), 'Product.props'))\Product.props" />
<Import Project="$(SourceRoot)\Product.props" />
<Import Project="$(PropsRoot)\_Nupkg.props" />

<PropertyGroup>
<RootNamespace>Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel</RootNamespace>
<AssemblyName>Microsoft.AI.ServerTelemetryChannel</AssemblyName>
<TargetFrameworks>net45;netstandard1.3;netstandard2.0</TargetFrameworks>
<TargetFrameworks Condition="$(OS) != 'Windows_NT'">netstandard1.3;netstandard2.0</TargetFrameworks>
</PropertyGroup>
Expand Down Expand Up @@ -112,6 +114,6 @@
</ItemGroup>

<Import Project="..\Common\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />

<Import Project="$(SourceRoot)\Common.targets" />
</Project>
1 change: 0 additions & 1 deletion LOGGING/Common.targets
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<Import Project="Signing.targets" />
<Import Project="$(TargetsRoot)\AddXmlLanguage.targets" />

</Project>
2 changes: 2 additions & 0 deletions LOGGING/src/Product.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.props'))\Common.props"/>

<Import Project="$(PropsRoot)\_Nupkg.props" />

<Import Project="$(TargetsRoot)\AddXmlLanguage.targets" />

<PropertyGroup>
<!--Removing the SRC folder from the output directory-->
Expand Down
6 changes: 0 additions & 6 deletions WEB/Common.targets

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -92,5 +92,4 @@

<Import Project="..\Shared\DependencyCollector.Shared.projitems" Label="Shared" />
<Import Project="..\..\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -102,5 +102,4 @@
<Import Project="..\..\TestFramework\Shared\TestFramework.Shared.projitems" Label="Shared" />
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,5 @@
</ItemGroup>

<Import Project="..\..\..\Src\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -95,5 +95,4 @@
</Choose>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -76,5 +76,4 @@
</ItemGroup>

<Import Project="..\..\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,5 @@
<Import Project="..\Perf.Shared.Tests\Perf.Shared.Tests.projitems" Label="Shared" />
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<Import Project="..\..\TestFramework\Shared\TestFramework.Shared.projitems" Label="Shared" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -94,5 +94,4 @@
<Import Project="..\Perf.Shared.NetStandard16.Stubs\Perf.Shared.NetStandard16.Stubs.projitems" Label="Shared" Condition="'$(TargetFramework)' == 'netstandard1.6'" />
<Import Project="..\Perf.Shared.NetStandard20\Perf.Shared.NetStandard20.projitems" Label="Shared" Condition="'$(TargetFramework)' == 'netstandard2.0'" />

<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
1 change: 0 additions & 1 deletion WEB/Src/PerformanceCollector/Xdt.Tests/Xdt.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -93,5 +93,4 @@
</Choose>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
11 changes: 2 additions & 9 deletions WEB/Src/Product.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,7 @@

<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove('$(MSBuildThisFileDirectory)\..', 'Common.props'))\Common.props" />
<Import Project="$(PropsRoot)\_Nupkg.props" />

<!--
Example of how to do logs:
Conditions are supported.
<Target Name="BuildLogs_HelloWorld" AfterTargets="CopyFilesToOutputDirectory" >
<Message Text="Hello World!" Importance="high" />
</Target>
-->

<Import Project="$(TargetsRoot)\AddXmlLanguage.targets" />

</Project>
1 change: 0 additions & 1 deletion WEB/Src/Web/Web.Net45.Tests/Web.Net45.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,5 @@
<Import Project="..\Web.Shared.Net.Tests\Web.Shared.Net.Tests.projitems" Label="Shared" />
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<Import Project="..\..\TestFramework\Shared\TestFramework.Shared.projitems" Label="Shared" />
</Project>
1 change: 0 additions & 1 deletion WEB/Src/Web/Web/Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,4 @@

<Import Project="..\Web.Shared.Net\Web.Shared.Net.projitems" Label="Shared" />
<Import Project="..\..\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@
</ItemGroup>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<Import Project="..\..\TestFramework\Shared\TestFramework.Shared.projitems" Label="Shared" />
<Import Project="..\WindowsServer.Shared.Tests\WindowsServer.Shared.Tests.projitems" Label="Shared" />
</Project>
1 change: 0 additions & 1 deletion WEB/Src/WindowsServer/WindowsServer/WindowsServer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,4 @@

<Import Project="..\WindowsServer.Shared\WindowsServer.Shared.projitems" Label="Shared" />
<Import Project="..\..\Common\Common.projitems" Label="Shared" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildProjectDirectory), 'Test.props'))\Test.props" />
<PropertyGroup>
<Company>Microsoft</Company>
<Copyright>Copyright © Microsoft. All Rights Reserved.</Copyright>
<Copyright>Copyright © Microsoft. All Rights Reserved.</Copyright>
<GenerateAssemblyVersionAttribute>false</GenerateAssemblyVersionAttribute>
<GenerateAssemblyFileVersionAttribute>false</GenerateAssemblyFileVersionAttribute>
<GenerateAssemblyInformationalVersionAttribute>false</GenerateAssemblyInformationalVersionAttribute>
Expand Down Expand Up @@ -88,5 +88,4 @@
<Link>StackFrame.bond</Link>
</BondCodegen>
</ItemGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
8 changes: 1 addition & 7 deletions WEB/Test/E2ETests/IngestionService/IngestionService.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -144,11 +144,5 @@
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -361,11 +361,5 @@
</PostBuildEvent>
</PropertyGroup>
<Import Project="..\..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets" Condition="Exists('..\..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets')" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -335,10 +335,5 @@
<Error Condition="!Exists('..\..\..\..\..\..\..\packages\Microsoft.Net.Compilers.1.3.2\build\Microsoft.Net.Compilers.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\..\..\..\..\packages\Microsoft.Net.Compilers.1.3.2\build\Microsoft.Net.Compilers.props'))" />
<Error Condition="!Exists('..\..\..\..\..\..\..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.3\build\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\..\..\..\..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.3\build\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.props'))" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target> -->

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -234,5 +234,4 @@
<Error Condition="!Exists('..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets'))" />
</Target>
<Import Project="..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets" Condition="Exists('..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets')" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,6 @@
</VisualStudio>
</ProjectExtensions>
<Import Project="$(SolutionDir)\Test.Common.Sdk.Net45.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<PropertyGroup Condition="$(BuildingInsideVisualStudio)!=''">
<RunPostBuildEvent>OnBuildSuccess</RunPostBuildEvent>
<PostBuildEvent>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,12 +207,5 @@
<Error Condition="!Exists('..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets'))" />
</Target>
<Import Project="..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets" Condition="Exists('..\..\..\..\..\..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\build\Microsoft.Diagnostics.Tracing.TraceEvent.targets')" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->

</Project>
9 changes: 1 addition & 8 deletions WEB/Test/Web/FunctionalTests/StressTest/StressTest.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,5 @@
<None Include="App.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -415,5 +415,4 @@
</PostBuildEvent>
</PropertyGroup>
<Import Project="$(SolutionDir)\FunctionalTests\Test.Common.Sdk.Net45.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
9 changes: 1 addition & 8 deletions WEB/Test/Web/FunctionalTests/TestApps/Aspx45/Aspx45.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -405,12 +405,5 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -104,5 +104,4 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -414,5 +414,4 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -227,5 +227,4 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -158,5 +158,4 @@
</VisualStudio>
</ProjectExtensions>
<Import Project="$(SolutionDir)\FunctionalTests\Test.Common.Sdk.Net45.targets" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -214,5 +214,4 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -185,5 +185,4 @@
copy "$(TargetDir)" "$(ProjectDir)bin"
</PostBuildEvent>
</PropertyGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'Common.targets'))\Common.targets" />
</Project>

0 comments on commit e821aab

Please sign in to comment.