From 557f11b22bac1e8dc0df306395598ca27d75b515 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:26:33 +0000 Subject: [PATCH 1/5] Initial plan From e993bba7ca0b9c6872615db9e5a0a6e5b4016518 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:33:06 +0000 Subject: [PATCH 2/5] Add framework-dependent build support without .NET runtime Co-authored-by: VictoriousRaptor <10308169+VictoriousRaptor@users.noreply.github.com> --- .github/workflows/dotnet.yml | 16 +++++++- .../Net9.0-FrameworkDependent.pubxml | 18 +++++++++ Scripts/post_build.ps1 | 39 +++++++++++++------ appveyor.yml | 10 +++-- 4 files changed, 68 insertions(+), 15 deletions(-) create mode 100644 Flow.Launcher/Properties/PublishProfiles/Net9.0-FrameworkDependent.pubxml diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 0659ae64583..c05cec03549 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -65,7 +65,14 @@ jobs: with: name: Flow Installer path: | - Output\Packages\Flow-Launcher-*.exe + Output\Packages\Flow-Launcher-Setup.exe + compression-level: 0 + - name: Upload Framework-Dependent Setup + uses: actions/upload-artifact@v6 + with: + name: Flow Installer Framework-Dependent + path: | + Output\Packages\Flow-Launcher-Setup-FD.exe compression-level: 0 - name: Upload Portable Version uses: actions/upload-artifact@v6 @@ -74,6 +81,13 @@ jobs: path: | Output\Packages\Flow-Launcher-Portable.zip compression-level: 0 + - name: Upload Framework-Dependent Portable Version + uses: actions/upload-artifact@v6 + with: + name: Portable Version Framework-Dependent + path: | + Output\Packages\Flow-Launcher-Portable-FD.zip + compression-level: 0 - name: Upload Full Nupkg uses: actions/upload-artifact@v6 with: diff --git a/Flow.Launcher/Properties/PublishProfiles/Net9.0-FrameworkDependent.pubxml b/Flow.Launcher/Properties/PublishProfiles/Net9.0-FrameworkDependent.pubxml new file mode 100644 index 00000000000..1d640ea150d --- /dev/null +++ b/Flow.Launcher/Properties/PublishProfiles/Net9.0-FrameworkDependent.pubxml @@ -0,0 +1,18 @@ + + + + + FileSystem + Release + Any CPU + net9.0-windows10.0.19041.0 + ..\Output\Release-FD\ + win-x64 + false + False + False + False + + diff --git a/Scripts/post_build.ps1 b/Scripts/post_build.ps1 index dc7c39407ef..e0d4c531aee 100644 --- a/Scripts/post_build.ps1 +++ b/Scripts/post_build.ps1 @@ -61,18 +61,17 @@ function Validate-Directory ($output) { } -function Pack-Squirrel-Installer ($path, $version, $output) { +function Pack-Squirrel-Installer ($path, $version, $output, $inputPath = "$path\Output\Release", $suffix = "") { # msbuild based installer generation is not working in appveyor, not sure why Write-Host "Begin pack squirrel installer" $spec = "$path\Scripts\flowlauncher.nuspec" - $input = "$path\Output\Release" Write-Host "Packing: $spec" - Write-Host "Input path: $input" + Write-Host "Input path: $inputPath" # dotnet pack is not used because ran into issues, need to test installation and starting up if to use it. - nuget pack $spec -Version $version -BasePath $input -OutputDirectory $output -Properties Configuration=Release + nuget pack $spec -Version $version -BasePath $inputPath -OutputDirectory $output -Properties Configuration=Release $nupkg = "$output\FlowLauncher.$version.nupkg" Write-Host "nupkg path: $nupkg" @@ -82,13 +81,13 @@ function Pack-Squirrel-Installer ($path, $version, $output) { New-Alias Squirrel $env:USERPROFILE\.nuget\packages\squirrel.windows\1.9.0\tools\Squirrel.exe -Force # why we need Write-Output: https://github.com/Squirrel/Squirrel.Windows/issues/489#issuecomment-156039327 # directory of releaseDir in squirrel can't be same as directory ($nupkg) in releasify - $temp = "$output\Temp" + $temp = "$output\Temp$suffix" Squirrel --releasify $nupkg --releaseDir $temp --setupIcon $icon --no-msi | Write-Output Move-Item $temp\* $output -Force Remove-Item $temp - $file = "$output\Flow-Launcher-Setup.exe" + $file = "$output\Flow-Launcher-Setup$suffix.exe" Write-Host "Filename: $file" Move-Item "$output\Setup.exe" $file -Force @@ -106,11 +105,22 @@ function Publish-Self-Contained ($p) { dotnet publish -c Release $csproj /p:PublishProfile=$profile } -function Publish-Portable ($outputLocation, $version) { +function Publish-Framework-Dependent ($p) { - & $outputLocation\Flow-Launcher-Setup.exe --silent | Out-Null + $csproj = Join-Path "$p" "Flow.Launcher/Flow.Launcher.csproj" -Resolve + $profile = Join-Path "$p" "Flow.Launcher/Properties/PublishProfiles/Net9.0-FrameworkDependent.pubxml" -Resolve + + # we call dotnet publish on the main project. + # The other projects should have been built in Release at this point. + dotnet publish -c Release $csproj /p:PublishProfile=$profile +} + +function Publish-Portable ($outputLocation, $version, $suffix = "") { + + & "$outputLocation\Flow-Launcher-Setup$suffix.exe" --silent | Out-Null mkdir "$env:LocalAppData\FlowLauncher\app-$version\UserData" - Compress-Archive -Path $env:LocalAppData\FlowLauncher -DestinationPath $outputLocation\Flow-Launcher-Portable.zip + Compress-Archive -Path $env:LocalAppData\FlowLauncher -DestinationPath "$outputLocation\Flow-Launcher-Portable$suffix.zip" -Force + Remove-Item "$env:LocalAppData\FlowLauncher" -Recurse -Force } function Main { @@ -122,15 +132,22 @@ function Main { Delete-Unused $p $config + # Build self-contained version (includes .NET runtime) + Write-Host "Building self-contained version..." Publish-Self-Contained $p - Remove-CreateDumpExe $p $config $o = "$p\Output\Packages" Validate-Directory $o Pack-Squirrel-Installer $p $v $o - Publish-Portable $o $v + + # Build framework-dependent version (requires .NET runtime to be installed) + Write-Host "Building framework-dependent version..." + Publish-Framework-Dependent $p + Remove-CreateDumpExe $p "Release-FD" + Pack-Squirrel-Installer $p $v $o "$p\Output\Release-FD" "-FD" + Publish-Portable $o $v "-FD" } } diff --git a/appveyor.yml b/appveyor.yml index 03542e8d2a8..98d6f56ef9f 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -49,10 +49,14 @@ after_test: artifacts: - path: 'Output\Release\Flow.Launcher.Plugin.*.nupkg' name: Plugin nupkg -- path: 'Output\Packages\Flow-Launcher-*.exe' +- path: 'Output\Packages\Flow-Launcher-Setup.exe' name: Squirrel Installer +- path: 'Output\Packages\Flow-Launcher-Setup-FD.exe' + name: Squirrel Installer Framework-Dependent - path: Output\Packages\Flow-Launcher-Portable.zip name: Portable Version +- path: Output\Packages\Flow-Launcher-Portable-FD.zip + name: Portable Version Framework-Dependent - path: 'Output\Packages\FlowLauncher-*-full.nupkg' name: Squirrel nupkg - path: 'Output\Packages\RELEASES' @@ -82,7 +86,7 @@ deploy: Please report any bugs or issues over at the [main repository](https://github.com/Flow-Launcher/Flow.Launcher/issues)' auth_token: secure: ij4UeXUYQBDJxn2YRAAhUOjklOGVKDB87Hn5J8tKIzj13yatoI7sLM666QDQFEgv - artifact: Squirrel Installer, Portable Version, Squirrel nupkg, Squirrel RELEASES + artifact: Squirrel Installer, Squirrel Installer Framework-Dependent, Portable Version, Portable Version Framework-Dependent, Squirrel nupkg, Squirrel RELEASES force_update: true on: branch: dev @@ -91,7 +95,7 @@ deploy: release: v$(flowVersion) auth_token: secure: ij4UeXUYQBDJxn2YRAAhUOjklOGVKDB87Hn5J8tKIzj13yatoI7sLM666QDQFEgv - artifact: Squirrel Installer, Portable Version, Squirrel nupkg, Squirrel RELEASES + artifact: Squirrel Installer, Squirrel Installer Framework-Dependent, Portable Version, Portable Version Framework-Dependent, Squirrel nupkg, Squirrel RELEASES draft: true force_update: true on: From 5d4d05a0770ebb5c603b43d309f463f2d5680e4b Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:34:42 +0000 Subject: [PATCH 3/5] Fix nupkg naming conflict for framework-dependent builds Co-authored-by: VictoriousRaptor <10308169+VictoriousRaptor@users.noreply.github.com> --- Scripts/post_build.ps1 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Scripts/post_build.ps1 b/Scripts/post_build.ps1 index e0d4c531aee..7fe7d58fa69 100644 --- a/Scripts/post_build.ps1 +++ b/Scripts/post_build.ps1 @@ -74,6 +74,14 @@ function Pack-Squirrel-Installer ($path, $version, $output, $inputPath = "$path\ nuget pack $spec -Version $version -BasePath $inputPath -OutputDirectory $output -Properties Configuration=Release $nupkg = "$output\FlowLauncher.$version.nupkg" + + # Rename the nupkg file if this is the framework-dependent version to avoid conflicts + if ($suffix -ne "") { + $nupkgRenamed = "$output\FlowLauncher$suffix.$version.nupkg" + Move-Item $nupkg $nupkgRenamed -Force + $nupkg = $nupkgRenamed + } + Write-Host "nupkg path: $nupkg" $icon = "$path\Flow.Launcher\Resources\app.ico" Write-Host "icon: $icon" From 99bb524fbca536263b44d1de55db8795f8ebcdfa Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:35:39 +0000 Subject: [PATCH 4/5] Update README with framework-dependent package information Co-authored-by: VictoriousRaptor <10308169+VictoriousRaptor@users.noreply.github.com> --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index e7595fff5d5..e9b53c56004 100644 --- a/README.md +++ b/README.md @@ -44,6 +44,10 @@ Dedicated to making your work flow more seamless. Search everything from applica [Windows 10+ Installer](https://github.com/Flow-Launcher/Flow.Launcher/releases/latest/download/Flow-Launcher-Setup.exe) or [Portable Version](https://github.com/Flow-Launcher/Flow.Launcher/releases/latest/download/Flow-Launcher-Portable.zip) +> **Note:** The default installers include the .NET runtime. If you already have .NET 9.0 runtime installed, you can download smaller framework-dependent packages: +> - [Framework-Dependent Installer](https://github.com/Flow-Launcher/Flow.Launcher/releases/latest/download/Flow-Launcher-Setup-FD.exe) +> - [Framework-Dependent Portable Version](https://github.com/Flow-Launcher/Flow.Launcher/releases/latest/download/Flow-Launcher-Portable-FD.zip) + #### Winget ``` From 30a0468e53002f3c8fcbda9fa37e0484e85f384e Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:37:28 +0000 Subject: [PATCH 5/5] Extract hardcoded strings to constants for better maintainability Co-authored-by: VictoriousRaptor <10308169+VictoriousRaptor@users.noreply.github.com> --- Scripts/post_build.ps1 | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Scripts/post_build.ps1 b/Scripts/post_build.ps1 index 7fe7d58fa69..0e2a5e6fbc7 100644 --- a/Scripts/post_build.ps1 +++ b/Scripts/post_build.ps1 @@ -4,6 +4,11 @@ param( ) Write-Host "Config: $config" +# Constants for build configurations +$RELEASE_CONFIG = "Release" +$RELEASE_FD_CONFIG = "Release-FD" +$FD_SUFFIX = "-FD" + function Build-Version { if ([string]::IsNullOrEmpty($env:flowVersion)) { $targetPath = Join-Path $solution "Output/Release/Flow.Launcher.dll" -Resolve @@ -136,7 +141,7 @@ function Main { $v = Build-Version Copy-Resources $p - if ($config -eq "Release"){ + if ($config -eq $RELEASE_CONFIG){ Delete-Unused $p $config @@ -153,9 +158,9 @@ function Main { # Build framework-dependent version (requires .NET runtime to be installed) Write-Host "Building framework-dependent version..." Publish-Framework-Dependent $p - Remove-CreateDumpExe $p "Release-FD" - Pack-Squirrel-Installer $p $v $o "$p\Output\Release-FD" "-FD" - Publish-Portable $o $v "-FD" + Remove-CreateDumpExe $p $RELEASE_FD_CONFIG + Pack-Squirrel-Installer $p $v $o "$p\Output\$RELEASE_FD_CONFIG" $FD_SUFFIX + Publish-Portable $o $v $FD_SUFFIX } }