fix(process): hide console windows for spawned git/cmd subprocesses - #2460
Merged
Conversation
Route git/cmd/editor/bitfun.exe subprocess spawns through the upstream native process_manager helper (create_command / create_tokio_command), which applies CREATE_NO_WINDOW on Windows, preventing the flash of a console window that previously accompanied spawned git/cmd subprocesses from the CLI dispatch runner, desktop dispatch host, and workspace auto-index. Reuses bitfun_services_core::process_manager and the bitfun_core::util::process_manager re-export (TUI boundary compliant); zero new dependencies, zero Cargo.toml changes. Test: cargo check --jobs 4 -p bitfun-services-integrations --features workspace-search --all-targets && cargo check --jobs 4 -p bitfun-cli --all-targets && cargo check --jobs 4 -p bitfun-desktop --all-targets (expected green) AI: lightly tested
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.
Summary
Spawned
git/cmdsubprocesses (repository probing, workspace dispatch, external editor launch, commit verification, auto-indexing) could show a transient empty console (cmd) window on Windows because they were launched withoutCREATE_NO_WINDOW. This PR reuses the existing upstreamprocess_managermodule (bitfun_core::util::process_manager,bitfun_services_core::process_manager), which appliesCREATE_NO_WINDOWon Windows, and rewires the affected call sites tocreate_command(...)/create_tokio_command(...).Fixes #2458
Type and Areas
Type: bug fix
Areas: Rust core, desktop/Tauri, CLI
Motivation / Impact
The transient empty console window is disruptive in detached / background / worker contexts where no interactive console is expected. This change only suppresses the transient console window on Windows; no user-visible UI is altered.
Verification
GetConsoleWindow()FFI) confirms subprocesses spawned viaprocess_manager::create_commandreport no console, while a controlCommand::newreports a console — i.e.CREATE_NO_WINDOWtakes effect at runtime.cargo check --workspace,cargo check -p bitfun-desktop,cargo clippy, CLI tests) is enforced by the repository CI on this pull request.process_managerprimitive and only rewires the affected call sites.Reviewer Notes
No UI change, so no before/after screenshots are attached. Manual verification on Windows: launch the application and confirm no empty
cmdwindow flashes during backgroundgit/cmdsubprocess operations (the change is confined to suppressing the console window).Commits:
6721825d6fix(process): hide console windows for spawned git/cmd subprocesses— reuseprocess_manager(create_command/create_tokio_command) withCREATE_NO_WINDOWfor spawned git/cmd subprocesses.Checklist