Skip to content
This repository was archived by the owner on Mar 19, 2019. It is now read-only.

Commit 7ea2905

Browse files
author
Nate McMaster
committed
Update how PackageReference versions are set
Changes: - Remove floating versions - Disable myget feeds during a Universe build - Use package-specific MSBuild variables. Pattern = `packageId.Pascalize() + "PackageVersion"`, with a few exceptions.
1 parent 3749bce commit 7ea2905

File tree

11 files changed

+34
-180
lines changed

11 files changed

+34
-180
lines changed

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ project.lock.json
2929
.vscode/
3030
.build/
3131
.testPublish/
32-
32+
global.json
3333
korebuild-lock.txt
3434
*.g.targets
35-

Directory.Build.targets

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
<Project>
1+
<Project>
22
<Import Project="build\sources.props" />
33
<Import Project="build\dependencies.props" />
4-
<Import Project="build\dependencies.targets" />
5-
<Import Project="build\dependencies.g.targets" Condition="Exists('build\dependencies.g.targets') AND '$(DesignTimeBuild)' != 'true'" />
64
</Project>

build/common.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
</PropertyGroup>
1313

1414
<ItemGroup>
15-
<PackageReference Include="Internal.AspNetCore.Sdk" Version="$(InternalAspNetCoreSdkVersion)" PrivateAssets="All" />
15+
<PackageReference Include="Internal.AspNetCore.Sdk" Version="$(InternalAspNetCoreSdkPackageVersion)" PrivateAssets="All" />
1616
</ItemGroup>
1717

1818
</Project>

build/dependencies.props

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
11
<Project>
22
<PropertyGroup>
3-
<AspNetCoreVersion>2.0.0</AspNetCoreVersion>
4-
<CoreFxVersion>4.4.0</CoreFxVersion>
5-
<InternalAspNetCoreSdkVersion>2.0.1-rtm-15400</InternalAspNetCoreSdkVersion>
6-
<NETStandardImplicitPackageVersion>2.0.0</NETStandardImplicitPackageVersion>
7-
<NETStandardLibraryNETFrameworkVersion>2.0.0</NETStandardLibraryNETFrameworkVersion>
8-
<RuntimeFrameworkVersion Condition="'$(TargetFramework)'=='netcoreapp2.0'">2.0.0</RuntimeFrameworkVersion>
9-
<TestSdkVersion>15.3.0</TestSdkVersion>
10-
<XunitVersion>2.3.0-beta2-build3683</XunitVersion>
11-
<XunitRunnerVisualStudioVersion>2.3.0-beta2-build1317</XunitRunnerVisualStudioVersion>
3+
<InternalAspNetCoreSdkPackageVersion>2.0.2-beta-15522</InternalAspNetCoreSdkPackageVersion>
4+
<MicrosoftAspNetCoreAuthenticationCorePackageVersion>2.0.1-rtm-83</MicrosoftAspNetCoreAuthenticationCorePackageVersion>
5+
<MicrosoftAspNetCoreHostingPackageVersion>2.0.1-rtm-83</MicrosoftAspNetCoreHostingPackageVersion>
6+
<MicrosoftAspNetCoreTestingPackageVersion>2.0.0</MicrosoftAspNetCoreTestingPackageVersion>
7+
<MicrosoftExtensionsLoggingConsolePackageVersion>2.0.0</MicrosoftExtensionsLoggingConsolePackageVersion>
8+
<MicrosoftNetHttpHeadersPackageVersion>2.0.1-rtm-83</MicrosoftNetHttpHeadersPackageVersion>
9+
<MicrosoftNETTestSdkPackageVersion>15.3.0</MicrosoftNETTestSdkPackageVersion>
10+
<MicrosoftWin32RegistryPackageVersion>4.4.0</MicrosoftWin32RegistryPackageVersion>
11+
<SystemNetHttpWinHttpHandlerPackageVersion>4.4.0</SystemNetHttpWinHttpHandlerPackageVersion>
12+
<SystemSecurityPrincipalWindowsPackageVersion>4.4.0</SystemSecurityPrincipalWindowsPackageVersion>
13+
<XunitPackageVersion>2.3.0-beta2-build3683</XunitPackageVersion>
14+
<XunitRunnerVisualStudioPackageVersion>2.3.0-beta2-build1317</XunitRunnerVisualStudioPackageVersion>
1215
</PropertyGroup>
1316

1417
<Import Project="$(DotNetPackageVersionPropsPath)" Condition=" '$(DotNetPackageVersionPropsPath)' != '' " />

build/dependencies.targets

Lines changed: 0 additions & 149 deletions
This file was deleted.

build/sources.props

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,14 @@
33

44
<PropertyGroup>
55
<RestoreSources>$(DotNetRestoreSources)</RestoreSources>
6-
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true'">
6+
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true' AND '$(AspNetUniverseBuildOffline)' != 'true' ">
77
$(RestoreSources);
88
https://dotnet.myget.org/F/aspnet-2-0-2-october2017-patch/api/v3/index.json;
99
https://dotnet.myget.org/F/aspnetcore-master/api/v3/index.json;
1010
https://dotnet.myget.org/F/aspnetcore-tools/api/v3/index.json;
11+
</RestoreSources>
12+
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true'">
13+
$(RestoreSources);
1114
https://api.nuget.org/v3/index.json;
1215
</RestoreSources>
1316
</PropertyGroup>

samples/HotAddSample/HotAddSample.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88

99
<ItemGroup>
1010
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Server.HttpSys\Microsoft.AspNetCore.Server.HttpSys.csproj" />
11-
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="$(AspNetCoreVersion)" />
11+
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="$(MicrosoftExtensionsLoggingConsolePackageVersion)" />
1212
</ItemGroup>
1313
</Project>

samples/SelfHostServer/SelfHostServer.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88

99
<ItemGroup>
1010
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Server.HttpSys\Microsoft.AspNetCore.Server.HttpSys.csproj" />
11-
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="$(AspNetCoreVersion)" />
11+
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="$(MicrosoftExtensionsLoggingConsolePackageVersion)" />
1212
</ItemGroup>
1313
</Project>

src/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
</PropertyGroup>
1313

1414
<ItemGroup>
15-
<PackageReference Include="Microsoft.AspNetCore.Authentication.Core" Version="$(AspNetCoreVersion)" />
16-
<PackageReference Include="Microsoft.AspNetCore.Hosting" Version="$(AspNetCoreVersion)" />
17-
<PackageReference Include="Microsoft.Net.Http.Headers" Version="$(AspNetCoreVersion)" />
18-
<PackageReference Include="Microsoft.Win32.Registry" Version="$(CoreFxVersion)" />
19-
<PackageReference Include="System.Security.Principal.Windows" Version="$(CoreFxVersion)" />
15+
<PackageReference Include="Microsoft.AspNetCore.Authentication.Core" Version="$(MicrosoftAspNetCoreAuthenticationCorePackageVersion)" />
16+
<PackageReference Include="Microsoft.AspNetCore.Hosting" Version="$(MicrosoftAspNetCoreHostingPackageVersion)" />
17+
<PackageReference Include="Microsoft.Net.Http.Headers" Version="$(MicrosoftNetHttpHeadersPackageVersion)" />
18+
<PackageReference Include="Microsoft.Win32.Registry" Version="$(MicrosoftWin32RegistryPackageVersion)" />
19+
<PackageReference Include="System.Security.Principal.Windows" Version="$(SystemSecurityPrincipalWindowsPackageVersion)" />
2020
</ItemGroup>
2121

2222
</Project>

0 commit comments

Comments
 (0)