From 7a57a57acc436a4448c068c5394653ad0e72e4eb Mon Sep 17 00:00:00 2001 From: Eric Erhardt Date: Tue, 6 Jun 2017 22:08:22 -0500 Subject: [PATCH] Fix VersionSuffix for the managed projects VersionSuffix is getting set before $(BuildNumberMajor) and $(BuildNumberMinor) are being set. When creating the DependencyModel nupkg, it is getting a bad version on its p2p reference to PlatformAbstractions. The fix is to ensure VersionSuffix is defined correctly in the projects themselves - after the obj\BuildVersion.props file is created. Workaround https://github.com/NuGet/Home/issues/4337 Commit migrated from https://github.com/dotnet/core-setup/commit/df6ab9c2a48b47181bedfb2704888b074e8a269a --- src/installer/BranchInfo.props | 13 +++++++++++ src/installer/build.proj | 19 ++-------------- src/installer/managed/CommonManaged.props | 36 +++++++++++++++++++++++++++++-- src/installer/pkg/packaging/dir.proj | 3 +-- src/installer/restore.proj | 10 --------- 5 files changed, 50 insertions(+), 31 deletions(-) create mode 100644 src/installer/BranchInfo.props delete mode 100644 src/installer/restore.proj diff --git a/src/installer/BranchInfo.props b/src/installer/BranchInfo.props new file mode 100644 index 0000000..fa72178 --- /dev/null +++ b/src/installer/BranchInfo.props @@ -0,0 +1,13 @@ + + + 2 + 0 + 2 + false + servicing + $(PreReleaseLabel) + + release/2.0.0 + release/2.0.0 + + diff --git a/src/installer/build.proj b/src/installer/build.proj index 0cadd7b..bc22de9 100644 --- a/src/installer/build.proj +++ b/src/installer/build.proj @@ -17,7 +17,6 @@ CreateOrUpdateCurrentVersionFile; CreateVersionInfoFile; BatchRestorePackages; - ValidateExactRestore; BuildCustomTasks; @@ -59,22 +58,8 @@ - - - - - - - - - - - - - + + diff --git a/src/installer/managed/CommonManaged.props b/src/installer/managed/CommonManaged.props index 0c54133..341b2af 100644 --- a/src/installer/managed/CommonManaged.props +++ b/src/installer/managed/CommonManaged.props @@ -5,7 +5,24 @@ $([System.IO.Path]::GetFullPath('$(MSBuildThisFileDirectory)../..'))/ - 2.0.2 + + + + + + + $(RepoRoot)Bin/ + $(BinDir)obj/ + + + $([System.DateTime]::Now.ToString(yyyyMMdd)) + $(ObjDir)BuildVersion-$(TodayTimeStamp).props + + + + + + $(MajorVersion).$(MinorVersion).$(PatchVersion) $(VersionPrefix) true true @@ -17,6 +34,21 @@ $(RepoRoot)THIRD-PARTY-NOTICES.TXT + + + 9 + + + $(PreReleaseLabel)- + $(VersionSuffix)$(BuildNumberMajor)-$(BuildNumberMinor) + + $(RepoRoot)tools-local/setuptools/Key.snk true @@ -45,5 +77,5 @@ - + \ No newline at end of file diff --git a/src/installer/pkg/packaging/dir.proj b/src/installer/pkg/packaging/dir.proj index 9102701..bebdb48 100644 --- a/src/installer/pkg/packaging/dir.proj +++ b/src/installer/pkg/packaging/dir.proj @@ -183,10 +183,9 @@ --output $(PackagesOutDir) --configuration $(ConfigurationGroup) - --version-suffix $(VersionSuffix) - diff --git a/src/installer/restore.proj b/src/installer/restore.proj deleted file mode 100644 index ae55b08..0000000 --- a/src/installer/restore.proj +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - -- 2.7.4