You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
recover.rs uses std eprintln instead of anstream eprintln #1182
src/git/recover.rs (added in e40ed3a, #1146) uses the standard library's eprintln! macro instead of the project's crate::styling::eprintln (re-exported from anstream).
The rest of the codebase consistently uses the anstream-backed eprintln to ensure ANSI escape codes are stripped when stderr is not a terminal. The info_message() function returns a FormattedMessage containing ANSI codes (via cstr!("<dim>○</>")), so printing it with std::eprintln! would emit raw escape sequences when stderr is piped.
Add use crate::styling::eprintln; to the imports in recover.rs. This shadows the standard eprintln! macro with the anstream version, matching the pattern used in every other file that prints styled messages.
Impact
Minor — the recovery path only triggers in interactive scenarios (deleted CWD), so piped output is unlikely. But the inconsistency should be fixed to prevent copy-paste propagation.
Activity
fix: use anstream eprintln in recover.rs for proper ANSI handling