Skip to content

Commit

Permalink
Merge branch 'release/2.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
Nate McMaster committed Oct 31, 2018
2 parents 08ad740 + 18fcffb commit 34204b6
Show file tree
Hide file tree
Showing 255 changed files with 822 additions and 646 deletions.
24 changes: 21 additions & 3 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,38 @@
Condition=" '$(CI)' != 'true' AND '$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), AspNetCoreSettings.props))' != '' " />

<Import Project="version.props" />
<Import Project="build\dependencies.props" />
<Import Project="build\sources.props" />

<PropertyGroup>
<Product>Microsoft .NET Extensions</Product>
<RepositoryUrl>https://github.com/aspnet/Extensions</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<RepositoryRoot>$(MSBuildThisFileDirectory)</RepositoryRoot>
<AssemblyOriginatorKeyFile>$(MSBuildThisFileDirectory)build\Key.snk</AssemblyOriginatorKeyFile>
<AssemblyOriginatorKeyFile>$(MSBuildThisFileDirectory)eng\AspNetCore.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

<ArtifactsDir>$(MSBuildThisFileDirectory)artifacts\</ArtifactsDir>
<PackageOutputPath>$(MSBuildThisFileDirectory)artifacts\build\</PackageOutputPath>

<IsBenchmarkProject Condition="$(MSBuildProjectName.EndsWith('.Performance'))">true</IsBenchmarkProject>
<IsTestProject Condition="$(MSBuildProjectName.EndsWith('Tests')) OR $(MSBuildProjectName.EndsWith('.Test'))">true</IsTestProject>
<UseLatestPackageReferences Condition=" '$(PatchVersion)' == '0' OR '$(IsTestProject)' == 'true' OR '$(IsBenchmarkProject)' == 'true'">true</UseLatestPackageReferences>

<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
</PropertyGroup>

<PropertyGroup>
<DeveloperBuildTestTfms>netcoreapp3.0</DeveloperBuildTestTfms>
<StandardTestTfms>$(DeveloperBuildTestTfms)</StandardTestTfms>
<StandardTestTfms Condition=" '$(DeveloperBuild)' != 'true' AND '$(OS)' == 'Windows_NT' ">$(StandardTestTfms);net461</StandardTestTfms>
</PropertyGroup>

<Import Project="eng\Baseline.props" />
<Import Project="eng\Dependencies.props" />
<Import Project="eng\PatchConfig.props" />
<Import Project="eng\Sources.props" />

<ItemGroup>
<PackageReference Include="Internal.AspNetCore.Sdk" PrivateAssets="All" Version="$(InternalAspNetCoreSdkPackageVersion)" />
</ItemGroup>
</Project>
3 changes: 3 additions & 0 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,7 @@
<RuntimeFrameworkVersion Condition=" '$(TargetFramework)' == 'netcoreapp3.0' ">$(MicrosoftNETCoreAppPackageVersion)</RuntimeFrameworkVersion>
<NETStandardImplicitPackageVersion Condition=" '$(TargetFramework)' == 'netstandard2.0' ">$(NETStandardLibrary20PackageVersion)</NETStandardImplicitPackageVersion>
</PropertyGroup>

<Import Project="eng\targets\Packaging.targets" Condition=" '$(MSBuildProjectExtension)' == '.csproj' " />
<Import Project="eng\targets\ResolveReferences.targets" Condition=" '$(MSBuildProjectExtension)' == '.csproj' " />
</Project>
374 changes: 248 additions & 126 deletions Extensions.sln

Large diffs are not rendered by default.

36 changes: 0 additions & 36 deletions build/dependencies.props

This file was deleted.

11 changes: 10 additions & 1 deletion build/repo.props
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
<Project>
<Import Project="dependencies.props" />
<Import Project="..\eng\Dependencies.props" />

<PropertyGroup>
<EnableBenchmarkValidation>true</EnableBenchmarkValidation>
<SkipArtifactVerification>true</SkipArtifactVerification>
<DisablePackageReferenceRestrictions>true</DisablePackageReferenceRestrictions>
<BuildSolutions>false</BuildSolutions>
<SharedSourcesFolder>$(RepositoryRoot)src\Shared\src\</SharedSourcesFolder>
<SolutionProperties>$(SolutionProperties);DotNetPackageVersionPropsPath=$(DotNetPackageVersionPropsPath)</SolutionProperties>
<SolutionProperties>$(SolutionProperties);DotNetAdditionalRestoreSources=$(DotNetAdditionalRestoreSources)</SolutionProperties>
<Projects>$(RepositoryRoot)src\**\*.csproj</Projects>
</PropertyGroup>

<ItemGroup>
<SharedSourceDirectories Include="$([System.IO.Directory]::GetDirectories($(SharedSourcesFolder)))" />
</ItemGroup>

<ItemGroup>
<DotNetCoreRuntime Include="$(MicrosoftNETCoreAppPackageVersion)"
Feed="$(DotNetAssetRootUrl)"
Expand Down
File renamed without changes.
29 changes: 29 additions & 0 deletions eng/Baseline.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<!-- Auto generated. Do not edit manually, use eng/tools/BaselineGenerator/ to recreate. -->
<Project>
<!-- Package: Microsoft.Extensions.DiagnosticAdapter-->
<PropertyGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.DiagnosticAdapter' ">
<BaselinePackageVersion>2.1.0</BaselinePackageVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.DiagnosticAdapter' AND '$(TargetFramework)' == 'net461' ">
<BaselinePackageReference Include="System.Diagnostics.DiagnosticSource" Version="[4.5.0, )" />
</ItemGroup>
<ItemGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.DiagnosticAdapter' AND '$(TargetFramework)' == 'netcoreapp2.0' ">
<BaselinePackageReference Include="System.Diagnostics.DiagnosticSource" Version="[4.5.0, )" />
</ItemGroup>
<ItemGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.DiagnosticAdapter' AND '$(TargetFramework)' == 'netstandard2.0' ">
<BaselinePackageReference Include="System.Diagnostics.DiagnosticSource" Version="[4.5.0, )" />
</ItemGroup>
<!-- Package: Microsoft.Extensions.ObjectPool-->
<PropertyGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.ObjectPool' ">
<BaselinePackageVersion>2.1.1</BaselinePackageVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.ObjectPool' AND '$(TargetFramework)' == 'netstandard2.0' " />
<!-- Package: Microsoft.Extensions.Primitives-->
<PropertyGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.Primitives' ">
<BaselinePackageVersion>2.1.1</BaselinePackageVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(PackageId)' == 'Microsoft.Extensions.Primitives' AND '$(TargetFramework)' == 'netstandard2.0' ">
<BaselinePackageReference Include="System.Memory" Version="[4.5.1, )" />
<BaselinePackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="[4.5.1, )" />
</ItemGroup>
</Project>
65 changes: 65 additions & 0 deletions eng/Dependencies.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
<Project>
<PropertyGroup>
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
</PropertyGroup>

<!-- These package versions may be overridden or updated by automation. -->
<PropertyGroup Label="Package Versions: Auto">
<FSharpCorePackageVersion>4.2.1</FSharpCorePackageVersion>
<InternalAspNetCoreSdkPackageVersion>3.0.0-alpha1-20181030.4</InternalAspNetCoreSdkPackageVersion>
<MicrosoftNETCoreAppPackageVersion>3.0.0-preview1-26907-05</MicrosoftNETCoreAppPackageVersion>
<MicrosoftWin32RegistryPackageVersion>4.6.0-preview1-26907-04</MicrosoftWin32RegistryPackageVersion>
<NETStandardLibrary20PackageVersion>2.0.3</NETStandardLibrary20PackageVersion>
<SystemDiagnosticsDiagnosticSourcePackageVersion>4.6.0-preview1-26907-04</SystemDiagnosticsDiagnosticSourcePackageVersion>
<SystemIOPipelinesPackageVersion>4.6.0-preview1-26907-04</SystemIOPipelinesPackageVersion>
<SystemMemoryPackageVersion>4.6.0-preview1-26717-04</SystemMemoryPackageVersion>
<SystemNetHttpPackageVersion>4.3.2</SystemNetHttpPackageVersion>
<SystemReflectionMetadataPackageVersion>1.7.0-preview1-26907-04</SystemReflectionMetadataPackageVersion>
<SystemRuntimeCompilerServicesUnsafePackageVersion>4.6.0-preview1-26907-04</SystemRuntimeCompilerServicesUnsafePackageVersion>
<SystemRuntimeInteropServicesRuntimeInformationPackageVersion>4.3.0</SystemRuntimeInteropServicesRuntimeInformationPackageVersion>
<SystemSecurityCryptographyCngPackageVersion>4.6.0-preview1-26907-04</SystemSecurityCryptographyCngPackageVersion>
<SystemThreadingTasksExtensionsPackageVersion>4.6.0-preview1-26907-04</SystemThreadingTasksExtensionsPackageVersion>
<SystemValueTuplePackageVersion>4.6.0-preview1-26829-04</SystemValueTuplePackageVersion>
</PropertyGroup>

<!-- This may import a generated file which may override the variables above. -->
<Import Project="$(DotNetPackageVersionPropsPath)" Condition=" '$(DotNetPackageVersionPropsPath)' != '' " />

<ItemGroup Label=".NET Core dependencies">
<LatestPackageReference Include="FSharp.Core" Version="$(FSharpCorePackageVersion)" />
<LatestPackageReference Include="Microsoft.Win32.Registry" Version="$(MicrosoftWin32RegistryPackageVersion)" />
<LatestPackageReference Include="System.Diagnostics.DiagnosticSource" Version="$(SystemDiagnosticsDiagnosticSourcePackageVersion)" />
<LatestPackageReference Include="System.IO.Pipelines" Version="$(SystemIOPipelinesPackageVersion)" />
<LatestPackageReference Include="System.Memory" Version="$(SystemMemoryPackageVersion)" />
<LatestPackageReference Include="System.Net.Http" Version="$(SystemNetHttpPackageVersion)" />
<LatestPackageReference Include="System.Reflection.Metadata" Version="$(SystemReflectionMetadataPackageVersion)" />
<LatestPackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="$(SystemRuntimeCompilerServicesUnsafePackageVersion)" />
<LatestPackageReference Include="System.Runtime.InteropServices.RuntimeInformation" Version="$(SystemRuntimeInteropServicesRuntimeInformationPackageVersion)" />
<LatestPackageReference Include="System.Security.Cryptography.Cng" Version="$(SystemSecurityCryptographyCngPackageVersion)" />
<LatestPackageReference Include="System.Threading.Tasks.Extensions" Version="$(SystemThreadingTasksExtensionsPackageVersion)" />
<LatestPackageReference Include="System.ValueTuple" Version="$(SystemValueTuplePackageVersion)" />
</ItemGroup>

<ItemGroup Label="External dependencies">
<LatestPackageReference Include="BenchmarkDotNet" Version="0.10.13" />
<LatestPackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="2.8.0" />
<LatestPackageReference Include="Microsoft.Extensions.DependencyModel" Version="2.1.0" />
<LatestPackageReference Include="Microsoft.NET.Test.Sdk" Version="15.9.0" />
<LatestPackageReference Include="Moq" Version="4.10.0" />
<LatestPackageReference Include="Newtonsoft.Json" Version="11.0.2" />
<LatestPackageReference Include="xunit.abstractions" Version="2.0.1" />
<LatestPackageReference Include="xunit.analyzers" Version="0.10.0" />
<LatestPackageReference Include="xunit.assert" Version="2.3.0" />
<LatestPackageReference Include="xunit.extensibility.execution" Version="2.3.0" />
<LatestPackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
<LatestPackageReference Include="xunit" Version="2.4.0" />
</ItemGroup>

<ItemGroup Condition=" '$(IsTestProject)' == 'true' ">
<Reference Include="Microsoft.NET.Test.Sdk" />
<Reference Include="Moq" />
<Reference Include="xunit" />
<Reference Include="xunit.analyzers" />
<Reference Include="xunit.runner.visualstudio" />
</ItemGroup>
</Project>
10 changes: 10 additions & 0 deletions eng/PatchConfig.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project>

<PropertyGroup Condition=" '$(VersionPrefix)' == '2.1.6' ">
<PackagesInPatch>
Microsoft.Extensions.ObjectPool;
Microsoft.Extensions.Primitives;
</PackagesInPatch>
</PropertyGroup>

</Project>
6 changes: 1 addition & 5 deletions build/sources.props → eng/Sources.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,12 @@

<PropertyGroup Label="RestoreSources">
<RestoreSources>$(DotNetRestoreSources)</RestoreSources>
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true' AND '$(AspNetUniverseBuildOffline)' != 'true' ">
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true' ">
$(RestoreSources);
https://dotnet.myget.org/F/dotnet-core/api/v3/index.json;
https://dotnet.myget.org/F/aspnetcore-dev/api/v3/index.json;
https://dotnet.myget.org/F/aspnetcore-tools/api/v3/index.json;
https://dotnet.myget.org/F/dotnet-core/api/v3/index.json;
https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json;
</RestoreSources>
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true'">
$(RestoreSources);
https://api.nuget.org/v3/index.json;
</RestoreSources>
<RestoreSources Condition=" '$(DotNetAdditionalRestoreSources)' != '' ">
Expand Down
1 change: 1 addition & 0 deletions eng/artifacts.props
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<PackageArtifact Include="Microsoft.Extensions.ClosedGenericMatcher.Sources" Category="noship" />
<PackageArtifact Include="Microsoft.Extensions.CommandLineUtils.Sources" Category="noship" />
<PackageArtifact Include="Microsoft.Extensions.CopyOnWriteDictionary.Sources" Category="noship" />
<PackageArtifact Include="Microsoft.Extensions.DiagnosticAdapter" />
<PackageArtifact Include="Microsoft.Extensions.HashCodeCombiner.Sources" Category="noship" />
<PackageArtifact Include="Microsoft.Extensions.NonCapturingTimer.Sources" Category="noship" />
<PackageArtifact Include="Microsoft.Extensions.ObjectMethodExecutor.Sources" Category="noship" />
Expand Down
2 changes: 1 addition & 1 deletion eng/scripts/UpdateDependencies.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if (-not $NoCommit) {
}

$repoRoot = Resolve-Path "$PSScriptRoot/../../"
$depsPath = Resolve-Path "$repoRoot/build/dependencies.props"
$depsPath = Resolve-Path "$repoRoot/eng/Dependencies.props"
[xml] $dependencies = LoadXml $depsPath

if ($BuildXml -like 'http*') {
Expand Down
2 changes: 1 addition & 1 deletion eng/scripts/common.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ function CommitUpdatedVersions(
{
$count = $updatedVars.Count
if ($count -gt 0) {
& git add build\dependencies.props
& git add eng\Dependencies.props

$gitConfigArgs = @()
if ($env:GITHUB_USER) {
Expand Down
18 changes: 18 additions & 0 deletions eng/targets/Packaging.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<Project>

<PropertyGroup>
<PackageId Condition=" '$(PackageId)' == '' ">$(AssemblyName)</PackageId>
</PropertyGroup>

<PropertyGroup Condition=" '$(IsPackable)' != 'false' AND '$(PatchVersion)' != '0' ">
<IsPackable>$(PackagesInPatch.Contains(' $(PackageId);'))</IsPackable>
</PropertyGroup>

<PropertyGroup Condition=" '$(IsPackable)' == 'false' AND '$(BaselinePackageVersion)' != '' ">
<!-- This keeps assembly and package versions consistent across patches. If a package is not included in a patch, its version should stay at the baseline. -->
<Version>$(BaselinePackageVersion).0</Version>
<AssemblyVersion>$(BaselinePackageVersion).0</AssemblyVersion>
<PackageVersion>$(BaselinePackageVersion)</PackageVersion>
</PropertyGroup>

</Project>
44 changes: 44 additions & 0 deletions eng/targets/ResolveReferences.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<Project>

<PropertyGroup>
<ResolveReferencesDependsOn>
ResolveCustomReferences;
$(ResolveReferencesDependsOn);
</ResolveReferencesDependsOn>
</PropertyGroup>

<Target Name="ResolveCustomReferences" BeforeTargets="CollectPackageReferences" Condition=" '$(DisableCustomReferenceResolution)' != 'true' AND '$(TargetFramework)' != '' ">

<ItemGroup>
<_ExplicitPackageReference Include="@(PackageReference)" Condition=" '%(PackageReference.IsImplicitlyDefined)' != 'true' " />
<_ExplicitPackageReference Remove="Internal.AspNetCore.Sdk" />
</ItemGroup>

<Error Condition="@(_ExplicitPackageReference->Count()) != 0"
Text="PackageReference items are not allowed. Use &lt;Reference&gt; instead. " />

<ItemGroup>
<UnusedBaselinePackageReference Include="@(BaselinePackageReference)" Exclude="@(Reference)" />
<UnusedLatestPackageReference Include="@(LatestPackageReference)" Exclude="@(Reference)" />

<PackageReference Condition="'$(UseLatestPackageReferences)' != 'true'"
Include="@(BaselinePackageReference)"
Exclude="@(UnusedBaselinePackageReference)"
IsImplicitlyDefined="true" />

<PackageReference Condition="'$(UseLatestPackageReferences)' == 'true'"
Include="@(LatestPackageReference)"
Exclude="@(UnusedLatestPackageReference)"
IsImplicitlyDefined="true" />

<Reference Remove="@(PackageReference)" />
</ItemGroup>

<Warning Condition="@(UnusedBaselinePackageReference->Count()) != 0"
Text="Package references changed since the last release. This could be a breaking change." />

<Error Condition="'$(TargetFrameworkIdentifier)' != '.NETFramework' AND '%(Reference.Identity)' != '' AND ! Exists('%(Reference.Identity)')"
Code="MSB3245"
Text="Could not resolve this reference. Could not locate the package or project for &quot;%(Reference.Identity)&quot;" />
</Target>
</Project>
16 changes: 16 additions & 0 deletions eng/tools/BaselineGenerator/BaselineGenerator.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.1</TargetFramework>
<StartArguments>-o "$(MSBuildThisFileDirectory)..\..\Baseline.props"</StartArguments>
<StartWorkingDirectory>$(MSBuildProjectDirectory)</StartWorkingDirectory>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="NuGet.Packaging" Version="4.8.0" />
</ItemGroup>

<Import Project="..\..\..\src\Shared\src\CommandLineUtils\Microsoft.Extensions.CommandLineUtils.Sources.projitems" Label="Shared" />

</Project>
Loading

0 comments on commit 34204b6

Please sign in to comment.