Add Windows support with an MSI installer - #1
Merged
Conversation
Core (all TDD'd, pure and testable on every platform): - expand(~) now falls back to %USERPROFILE% (expand_with_home is the pure body) - new fileflow_core::windows module: Win32_Volume JSON parsing (volume GUID, drive letter, removable/fixed kind), injection-safe eject script builder, Explorer /select argument, Windows-safe name sanitization - layout: render sanitizes segments on Windows (render_windows_safe testable everywhere); render_filename sanitizes the stem on Windows - ingest::eject dispatches per platform (diskutil / PowerShell Shell.Application); explicit EjectUnsupported elsewhere - Photos import fails loudly with PhotosUnsupported off macOS Tauri shell: - volume.rs split per platform: /Volumes + diskutil on macOS, PowerShell Win32_Volume on Windows (no console flash), stubs elsewhere - drive arrivals: FSEvents watcher on macOS, gentle polling thread on Windows - reveal opens Finder or Explorer; new get_platform command - Full Disk Access heuristics and the tray Photos item are macOS-gated MSI + guard rails: - bundle.windows with stable WiX upgradeCode and WebView2 downloadBootstrapper - npm run build:msi; config guarded by core tests (upgrade code, webview mode, .ico icon, version lockstep with package.json) CI runs the full test/clippy gauntlet on windows-latest and builds the MSI as an artifact. README documents Windows install, build, and file locations. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DJTErYrYaCuGdv2uB4obBB
Arylmera
marked this pull request as ready for review
July 16, 2026 15:51
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Brings FileFlow to Windows, distributed as an MSI installer, while keeping macOS the primary platform. Built test-first: every new cross-platform behaviour landed as a failing test before its implementation, and all the Windows logic that can be pure (parsing, command building, name sanitization) lives in
fileflow-coreso it is unit-tested on every platform — no Windows host needed to catch regressions.Core (
fileflow-core) — TDD, 24 new testsexpand("~/…")now falls back to%USERPROFILE%when$HOMEis absent; the pure bodyexpand_with_homeis directly tested.fileflow_core::windowsmodule (pure, compiled everywhere):Get-CimInstance Win32_Volume … | ConvertTo-Jsonoutput — volume GUID (the Windows analogue of the macOS volume UUID that decides which card rule fires), drive letter, label, removable/fixed kind; handles PowerShell's single-object collapse and letter-less recovery partitions;X:) using the Shell.Application COM verb — the same path as Explorer's Eject;explorer_select_argfor reveal-in-Explorer;sanitize_segment: makes rendered folder/file names legal on NTFS/exFAT (invalid chars, trailing dots/spaces, reserved device names likeCON), applied bylayout::render/render_filenameon Windows builds only.ingest::ejectdispatches per platform:diskutil(macOS), PowerShell (Windows), explicitEjectUnsupportedelsewhere.PhotosUnsupportedoff macOS — a Photos rule can never silently strand files.Tauri shell
volume.rssplit per platform behind one API:/Volumes+diskutil -pliston macOS; PowerShellWin32_VolumeJSON on Windows (spawned withCREATE_NO_WINDOW,plistdep now macOS-only); inert stubs elsewhere.%SystemDrive%on Windows (never ejected/wiped).reveal_in_finderopens Finder on macOS, Explorer (/select,) on Windows; newget_platformcommand; Full Disk Access heuristics and the tray "Import to Photos now" item are macOS-gated.MSI installer + guard rails
bundle.windowsconfig: stable WiXupgradeCode(so upgrades replace instead of duplicating) andwebviewInstallMode: downloadBootstrapper(fresh Windows 10 machines get WebView2 automatically).npm run build:msi→target/release/bundle/msi/FileFlow_x.y.z_x64_en-US.msi.bundle_conf_tests.rsguards the installer config in CI on every platform: upgrade code is a real GUID, WebView2 mode set, a.icoicon is listed, andtauri.conf.json/package.jsonversions stay in lockstep.UI
photosrule (config copied from a Mac) still renders instead of blanking the select.CI
windows-latestjob:cargo test --workspace,cargo clippy -D warnings, then builds the MSI and uploads it as an artifact — the installer is proven buildable on every PR.Verification
cargo test -p fileflow-core: 56 tests green (32 existing + 24 new).cargo clippy --workspace --all-targets --target x86_64-pc-windows-msvc -- -D warnings: clean (whole workspace cross-checked for the Windows target).tsc --noEmit+vite build: clean.🤖 Generated with Claude Code
https://claude.ai/code/session_01DJTErYrYaCuGdv2uB4obBB
Generated by Claude Code