diff --git a/Directory.Build.props b/Directory.Build.props index 8d7ffc0..cc59625 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -9,7 +9,7 @@ disable latest - 5.7.2 + 5.7.3 45 FitEdit diff --git a/Ui/FitEdit.Ui.Desktop/FitEdit.Ui.Desktop.csproj b/Ui/FitEdit.Ui.Desktop/FitEdit.Ui.Desktop.csproj index 5159172..857188d 100644 --- a/Ui/FitEdit.Ui.Desktop/FitEdit.Ui.Desktop.csproj +++ b/Ui/FitEdit.Ui.Desktop/FitEdit.Ui.Desktop.csproj @@ -30,33 +30,10 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Ui/FitEdit.Ui.Desktop/Program.cs b/Ui/FitEdit.Ui.Desktop/Program.cs index 2f87277..2a66b32 100644 --- a/Ui/FitEdit.Ui.Desktop/Program.cs +++ b/Ui/FitEdit.Ui.Desktop/Program.cs @@ -32,4 +32,4 @@ public static AppBuilder BuildAvaloniaApp() .UsePlatformDetect() .LogToTrace() .UseReactiveUI(); -} \ No newline at end of file +} diff --git a/Ui/FitEdit.Ui.Desktop/SquirrelAutoUpdater.cs b/Ui/FitEdit.Ui.Desktop/SquirrelAutoUpdater.cs new file mode 100644 index 0000000..5f28270 --- /dev/null +++ b/Ui/FitEdit.Ui.Desktop/SquirrelAutoUpdater.cs @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Ui/FitEdit.Ui.Desktop/VelopackAutoUpdater.cs b/Ui/FitEdit.Ui.Desktop/VelopackAutoUpdater.cs index 039ecfe..b2b99c5 100644 --- a/Ui/FitEdit.Ui.Desktop/VelopackAutoUpdater.cs +++ b/Ui/FitEdit.Ui.Desktop/VelopackAutoUpdater.cs @@ -55,4 +55,4 @@ private async Task CheckForUpdates(CancellationToken ct = default) Log.Error($"Problem checking or applying updates: {e}"); } } -} \ No newline at end of file +} diff --git a/Ui/FitEdit.Ui.Desktop/create-release-win.ps1 b/Ui/FitEdit.Ui.Desktop/create-release-win.ps1 index 89edfd6..1bb8b29 100644 --- a/Ui/FitEdit.Ui.Desktop/create-release-win.ps1 +++ b/Ui/FitEdit.Ui.Desktop/create-release-win.ps1 @@ -20,29 +20,80 @@ pushd $PSScriptRoot $certTmpPath = "$PSScriptRoot/$certTmpPath" echo "Created $certTmpPath..." -echo "Publishing..." -dotnet publish FitEdit.Ui.Desktop.csproj --configuration $configuration --runtime $rid --framework $framework --output "./bin/Release/$framework/publish/$rid/" --self-contained true -p:PublishSingleFile=true -p:PublishTrimmed=false - -echo "Packing..." - -vpk pack -y ` - --packId $packId ` - --packTitle "FitEdit" ` - --packAuthors $authors ` - --packVersion $version ` - --packDir "./bin/$configuration/$framework/publish/$rid/" ` - --icon "../FitEdit.Ui/Assets/logo.ico" ` - --mainExe "FitEdit.exe" ` - --outputDir "./Releases/$rid" ` - --delta None ` - --signParams="/f `"$certTmpPath`" /fd SHA256 /td SHA256 /tr http://timestamp.digicert.com /csp `"$csp`" /k $certKey" +$jobs = @() +$rids = @("win-x64", "win-arm64") + +# dotnet does not support publishing multiple RIDs in parallel +# Attempting to results in either +# project.assets.json doesn't have a target for +'net8.0-macos/osx-x64' +# or +# project.assets.json doesn't have a target for +'net8.0-macos/osx-arm64' +# depending on which built first +# +# https://github.com/dotnet/sdk/issues/9363 +foreach ($rid in $rids) { + + echo "Publishing $rid..." + dotnet publish FitEdit.Ui.Desktop.csproj ` + --configuration $configuration ` + --runtime $rid ` + --framework $framework ` + --output "./bin/$configuration/$framework/publish/$rid/" ` + --self-contained true ` + -p:PublishSingleFile=true ` + -p:PublishTrimmed=false + + if ($LASTEXITCODE -ne 0) { + exit $LASTEXITCODE + } +} + +foreach ($rid in $rids) { + echo "Packing $rid..." + $job = Start-ThreadJob { + # Create thread-local copies of these variables + $packId = $using:packId + $authors = $using:authors + $version = $using:version + $configuration = $using:configuration + $framework = $using:framework + $rid = $using:rid + $csp = $using:csp + $certKey = $using:certKey + $certTmpPath = $using:certTmpPath + + & { + vpk pack -y ` + --packId $packId ` + --packTitle "FitEdit" ` + --packAuthors $authors ` + --packVersion $version ` + --packDir "./bin/$configuration/$framework/publish/$rid/" ` + --icon "../FitEdit.Ui/Assets/logo.ico" ` + --mainExe "FitEdit.exe" ` + --outputDir "./Releases/$rid" ` + --delta None ` + --signParams="/f `"$certTmpPath`" /fd SHA256 /td SHA256 /tr http://timestamp.digicert.com /csp `"$csp`" /k $certKey" + + # Redirect all output (including stdout and stderr) to the main thread + # so it appears in the console and in CI build logs + } *>&1 | ForEach-Object { "[$rid] $_" } | Out-Host + + } -StreamingHost $Host + + # Add the job to the list + $jobs += $job +} + +# Wait for all jobs to complete +Wait-Job -Job $jobs Remove-Item -Path $certTmpPath $doSync = [System.Boolean]::Parse($sync) if ($doSync -ne $true) { - popd - return + popd + return } # Sync with s3 diff --git a/Ui/FitEdit.Ui.iOS/Info.plist b/Ui/FitEdit.Ui.iOS/Info.plist index e514c84..c9f929e 100644 --- a/Ui/FitEdit.Ui.iOS/Info.plist +++ b/Ui/FitEdit.Ui.iOS/Info.plist @@ -7,7 +7,7 @@ CFBundleIdentifier com.endurabyte.fitedit CFBundleShortVersionString - 5.7.2 + 5.7.3 LSRequiresIPhoneOS MinimumOSVersion