Avalonia Migration Refactor
TA
24d ago+25110+25110+01234567890123456789012345678901234567890123456789-2-2-0123456789
Summary
Migration to Avalonia, based on dev, with unrelated fixes split out.
could potentially resolves #894.
Build/artifact wiring
Flow.Launcher.slnaddsFlow.Launcher.Avaloniaso solution builds produce the Avalonia host.Flow.Launcher.Avalonia/Flow.Launcher.Avalonia.csprojwrites host output toOutput\Avalonia\$(Configuration).- Built-in plugin
.csprojfiles copy plugin outputs intoOutput\Avalonia\$(Configuration)\Plugins\...for Avalonia runtime loading. Scripts/post_build.ps1packages Avalonia setup/portable artifacts separately underOutput\Packages\Avalonia..github/workflows/dotnet.ymluploadsAvalonia SetupandAvalonia Portable Versionartifacts.
What changed in the existing WPF/shared surface
These are the non-Flow.Launcher.Avalonia/ changes reviewers should expect:
Flow.Launcher/Languages/en.xaml— shared localization keys used by Avalonia UI.Flow.Launcher.Infrastructure/Hotkey/GlobalHotkey.cs— exposes hotkey callback/key conversion needed by the Avalonia host.Flow.Launcher.Plugin/Interfaces/ISettingProvider.cs— addsCreateSettingPanelAvalonia()for native Avalonia plugin settings without exposing Avalonia types to WPF plugin reflection.- Built-in plugin
.csproj,Main.cs, andViews/Avalonia/*files — native Avalonia settings views and copy targets. Flow.Launcher.sln— includes the Avalonia project in normal solution builds.Scripts/post_build.ps1andScripts/flowlauncher-avalonia.nuspec— create Avalonia setup/portable artifacts without changing release deployment workflows..github/workflows/dotnet.yml— uploads Avalonia CI artifacts only.
Existing WPF behavior intentionally left alone
- WPF host runtime behavior was not intentionally refactored.
- Existing WPF plugin settings remain the compatibility/fallback path.
- The JsonStorage temp-file truncation fix was split out to PR #4558 and is no longer part of this PR.
Verification
CI artifact sizes from run 28725559998 before the JsonStorage split cleanup:
-
Flow Installer: 101,089,952 bytes -
Portable Version: 204,621,638 bytes -
Avalonia Setup: 85,188,274 bytes -
Avalonia Portable Version: 172,204,291 bytes -
The original Flow Launcher installer works.
-
The Avalonia installer works.
Review notes
Highest-risk areas:
Flow.Launcher.Avalonia/AvaloniaPublicAPI.csplugin API compatibility.Flow.Launcher.Avalonia/ViewModel/MainViewModel.csquery/result lifecycle and plugin async query behavior.Flow.Launcher.Avalonia/App.axaml.csstartup sequence, WPF resource compatibility shim, and plugin initialization.- Build artifact paths: Avalonia must stay under
Output\Avalonia\$(Configuration)so WPF package inputs underOutput\Releaseremain close todev.