Skip to content

Commit

Permalink
Trim leading zeros from AppX package version (dotnet/core-setup#2587)
Browse files Browse the repository at this point in the history
* Trim leading zeros from AppX package version

* Use properties for Build and Revision version for AppX.


Commit migrated from dotnet/core-setup@f76a4f8
  • Loading branch information
gkhanna79 authored Jun 1, 2017
1 parent 6282965 commit 5aad836
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
<AppxIdentityName>Microsoft.NET.CoreRuntime.$(MajorVersion).$(MinorVersion)</AppxIdentityName>
<AppxDisplayName>Microsoft.NET.CoreRuntime.$(MajorVersion).$(MinorVersion)</AppxDisplayName>

<BuildVersionAppX>$([System.Int32]::Parse($(BuildNumberMajor)))</BuildVersionAppX>
<RevisionVersionAppX>$([System.Int32]::Parse($(BuildNumberMinor)))</RevisionVersionAppX>

<!-- path to contents of appx that will be zipped -->
<AppxOutputPath>$(IntermediateOutputPath)$(AppxIdentityName)</AppxOutputPath>
<OutputPath>$(IntermediateOutputPath)$(AppxIdentityName)</OutputPath>
Expand Down Expand Up @@ -61,7 +64,7 @@
Inputs="$(AppxManifestTemplate)"
Outputs="$(AppxManifest)">
<WriteLinesToFile File="$(AppxManifest)"
Lines="$([System.IO.File]::ReadAllText($(AppxManifestTemplate)).Replace('[AppxBuildArch]', $(Platform)).Replace('[AppxVersion]',$(MajorVersion).$(MinorVersion).$(BuildNumberMajor).$(BuildNumberMinor)).Replace('[AppxIdentityName]',$(AppxIdentityName)).Replace('[AppxDisplayName]',$(AppxDisplayName)))"
Lines="$([System.IO.File]::ReadAllText($(AppxManifestTemplate)).Replace('[AppxBuildArch]', $(Platform)).Replace('[AppxVersion]',$(MajorVersion).$(MinorVersion).$(BuildVersionAppX).$(RevisionVersionAppX)).Replace('[AppxIdentityName]',$(AppxIdentityName)).Replace('[AppxDisplayName]',$(AppxDisplayName)))"
Overwrite="true" />
<ItemGroup>
<FileWrites Include="$(AppxManifest)" />
Expand Down

0 comments on commit 5aad836

Please sign in to comment.