Feature: [Actions] Package builds for the Windows Store automatically

This commit is contained in:
Owen Rudge
2021-02-04 22:09:38 +00:00
parent 5b86bce7b2
commit 5a6ea11ead
12 changed files with 523 additions and 0 deletions

View File

@@ -0,0 +1,23 @@
[CmdletBinding()]
[Alias()]
Param
(
# EXE path
[Parameter(Mandatory=$true, Position=0)]
$ExePath
)
try
{
$versionInfo = (Get-Item "$ExePath").VersionInfo
# Generate the app version - the build number (MS calls it revision) is always 0 because the Windows Store requires that
$AppVersion = "$($versionInfo.FileMajorPart).$($versionInfo.FileMinorPart).$($versionInfo.FileBuildPart).0"
Write-Output "SET OTTD_VERSION=$($AppVersion)"
}
catch
{
Write-Output "@ECHO Error retrieving EXE version - did you provide a path?"
exit 1
}