diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 951b117..6181b87 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -47,14 +47,30 @@ jobs: $certificatePath = "GitHubActionsWorkflow.pfx" [IO.File]::WriteAllBytes("$env:Project_Name/$certificatePath", $pfx_cert_byte) + - name: Adjust Package Version + run: | + $epoch = (Get-Date) - ([System.DateTime]::new(2024, 11, 01)) + $file = (Resolve-Path "UniSky/Package.appxmanifest") + $xml = [System.Xml.XmlDocument]::new() + $xml.Load($file) + + $node = $xml.GetElementsByTagName("Identity", "http://schemas.microsoft.com/appx/manifest/foundation/windows10")[0] + $version = [System.Version]::Parse($node.GetAttribute("Version")) + $version = [System.Version]::new($version.Major, $version.Minor, $version.Build, $epoch.TotalMinutes); + $node.SetAttribute("Version", $version.ToString()) + + $xml.Save($file) + # Create the app package by building and packaging the project - name: Build App Packages - run: msbuild $env:ProjectFile_Name /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:AppxBundlePlatforms="x86|x64|ARM|ARM64" /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:AppxPackageDir="$env:Appx_Package_Dir" /p:GenerateAppxPackageOnBuild=true + run: msbuild $env:ProjectFile_Name /p:Configuration=$env:Configuration /p:SourceRevisionBranch="$env:Head_Ref" /p:SourceRevisionCommit="$($env:Sha.Substring(0, 7))" /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:AppxBundlePlatforms="x86|x64|ARM|ARM64" /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:AppxPackageDir="$env:Appx_Package_Dir" /p:GenerateAppxPackageOnBuild=true env: Appx_Bundle: Always Appx_Package_Build_Mode: SideloadOnly Appx_Package_Dir: Packages\ Configuration: ${{ matrix.configuration }} + Head_Ref: ${{ github.head_ref }} + Sha: ${{ github.sha }} # Remove the pfx - name: Cleanup @@ -67,7 +83,3 @@ jobs: name: AppxPackage-${{ matrix.configuration }} path: | ${{ env.Project_Name }}\\Packages - ${{ env.Project_Name }}\\bin\\x86\\${{ matrix.configuration }}\\ilc\\${{ env.Project_Name }}.pdb - ${{ env.Project_Name }}\\bin\\x64\\${{ matrix.configuration }}\\ilc\\${{ env.Project_Name }}.pdb - ${{ env.Project_Name }}\\bin\\ARM\\${{ matrix.configuration }}\\ilc\\${{ env.Project_Name }}.pdb - ${{ env.Project_Name }}\\bin\\ARM64\\${{ matrix.configuration }}\\ilc\\${{ env.Project_Name }}.pdb diff --git a/UniSky.Models/UniSky.Models.csproj b/UniSky.Models/UniSky.Models.csproj index 522f976..6668ea8 100644 --- a/UniSky.Models/UniSky.Models.csproj +++ b/UniSky.Models/UniSky.Models.csproj @@ -7,8 +7,22 @@ - - + + + + + + + + + + + + $(SourceRevisionCommit) + $(SourceRevisionCommit) ($(SourceRevisionBranch)) + + + diff --git a/UniSky/App.xaml b/UniSky/App.xaml index f3418e3..4d877b5 100644 --- a/UniSky/App.xaml +++ b/UniSky/App.xaml @@ -4,44 +4,42 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:UniSky" xmlns:controls="using:Microsoft.UI.Xaml.Controls" - xmlns:media="using:Microsoft.UI.Xaml.Media"> + xmlns:media="using:Microsoft.UI.Xaml.Media" + xmlns:sheets="using:UniSky.Controls.Sheet" + xmlns:themes="using:UniSky.Themes"> + + + + + - - - - - - - - - - - M13.873 3.77C21.21 9.243 29.103 20.342 32 26.3v15.732c0-.335-.13.043-.41.858-1.512 4.414-7.418 21.642-20.923 7.87-7.111-7.252-3.819-14.503 9.125-16.692-7.405 1.252-15.73-.817-18.014-8.93C1.12 22.804 0 8.431 0 6.488 0-3.237 8.579-.18 13.873 3.77ZM50.127 3.77C42.79 9.243 34.897 20.342 32 26.3v15.732c0-.335.13.043.41.858 1.512 4.414 7.418 21.642 20.923 7.87 7.111-7.252 3.819-14.503-9.125-16.692 7.405 1.252 15.73-.817 18.014-8.93C62.88 22.804 64 8.431 64 6.488 64-3.237 55.422-.18 50.127 3.77Z - 64 - 57 - - + + + + - 0,1,0,0 - 0,0,0,0 - 14 - 14 + 14 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +