fix(cmd): extract orphan cleanup to platform-specific files (#835)

PR #759 introduced cleanupOrphanedClaude() using syscall.Kill directly,
which breaks Windows builds. This extracts the function to:
- start_orphan_unix.go: Full implementation with SIGTERM/SIGKILL
- start_orphan_windows.go: Stub (orphan signals not supported)

Follows existing pattern: process_unix.go / process_windows.go
This commit is contained in:
Serhii
2026-01-21 08:34:37 +02:00
committed by John Ogle
parent 123c7407fc
commit fd39b99f0e
3 changed files with 104 additions and 78 deletions

View File

@@ -0,0 +1,16 @@
//go:build windows
package cmd
import (
"fmt"
"github.com/steveyegge/gastown/internal/style"
)
// cleanupOrphanedClaude is a Windows stub.
// Orphan cleanup requires Unix-specific signals (SIGTERM/SIGKILL).
func cleanupOrphanedClaude(graceSecs int) {
fmt.Printf(" %s Orphan cleanup not supported on Windows\n",
style.Dim.Render("○"))
}