fix(tui): suppress preflight stdout output in TUI mode to prevent scrambled display
- Add silentMode field to restore Engine struct - Set silentMode=true in NewSilent() constructor for TUI mode - Skip fmt.Println output in printPreflightSummary when in silent mode - Log summary instead of printing to stdout in TUI mode - Fixes scrambled output during cluster restore preflight checks
This commit is contained in:
@@ -50,6 +50,7 @@ type Engine struct {
|
||||
progress progress.Indicator
|
||||
detailedReporter *progress.DetailedReporter
|
||||
dryRun bool
|
||||
silentMode bool // Suppress stdout output (for TUI mode)
|
||||
debugLogPath string // Path to save debug log on error
|
||||
|
||||
// TUI progress callback for detailed progress reporting
|
||||
@@ -86,6 +87,7 @@ func NewSilent(cfg *config.Config, log logger.Logger, db database.Database) *Eng
|
||||
progress: progressIndicator,
|
||||
detailedReporter: detailedReporter,
|
||||
dryRun: false,
|
||||
silentMode: true, // Suppress stdout for TUI
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user