@@ -311,11 +311,11 @@ impl FsWrite {
311311 let relative_path = format_path ( cwd, & path) ;
312312 let prev = if os. fs . exists ( & path) {
313313 let file = os. fs . read_to_string_sync ( & path) ?;
314- stylize_output_if_able ( os , & path, & file)
314+ stylize_output_if_able ( & path, & file)
315315 } else {
316316 Default :: default ( )
317317 } ;
318- let new = stylize_output_if_able ( os , & relative_path, & file_text) ;
318+ let new = stylize_output_if_able ( & relative_path, & file_text) ;
319319 print_diff ( output, & prev, & new, 1 ) ?;
320320
321321 // Display summary as purpose if available after the diff
@@ -343,8 +343,8 @@ impl FsWrite {
343343 let old = [ prefix, insert_line_content, suffix] . join ( "" ) ;
344344 let new = [ prefix, insert_line_content, new_str, suffix] . join ( "" ) ;
345345
346- let old = stylize_output_if_able ( os , & relative_path, & old) ;
347- let new = stylize_output_if_able ( os , & relative_path, & new) ;
346+ let old = stylize_output_if_able ( & relative_path, & old) ;
347+ let new = stylize_output_if_able ( & relative_path, & new) ;
348348 print_diff ( output, & old, & new, start_line) ?;
349349
350350 // Display summary as purpose if available after the diff
@@ -362,8 +362,8 @@ impl FsWrite {
362362 Some ( ( start_line, end_line) ) => ( start_line, end_line) ,
363363 _ => ( 0 , 0 ) ,
364364 } ;
365- let old_str = stylize_output_if_able ( os , & relative_path, old_str) ;
366- let new_str = stylize_output_if_able ( os , & relative_path, new_str) ;
365+ let old_str = stylize_output_if_able ( & relative_path, old_str) ;
366+ let new_str = stylize_output_if_able ( & relative_path, new_str) ;
367367 print_diff ( output, & old_str, & new_str, start_line) ?;
368368
369369 // Display summary as purpose if available after the diff
@@ -375,7 +375,7 @@ impl FsWrite {
375375 let path = sanitize_path_tool_arg ( os, path) ;
376376 let relative_path = format_path ( cwd, & path) ;
377377 let start_line = os. fs . read_to_string_sync ( & path) ?. lines ( ) . count ( ) + 1 ;
378- let file = stylize_output_if_able ( os , & relative_path, new_str) ;
378+ let file = stylize_output_if_able ( & relative_path, new_str) ;
379379 print_diff ( output, & Default :: default ( ) , & file, start_line) ?;
380380
381381 // Display summary as purpose if available after the diff
@@ -763,8 +763,8 @@ fn terminal_width_required_for_line_count(line_count: usize) -> usize {
763763 line_count. to_string ( ) . chars ( ) . count ( )
764764}
765765
766- fn stylize_output_if_able ( os : & Os , path : impl AsRef < Path > , file_text : & str ) -> StylizedFile {
767- if supports_truecolor ( os ) {
766+ fn stylize_output_if_able ( path : impl AsRef < Path > , file_text : & str ) -> StylizedFile {
767+ if supports_truecolor ( ) {
768768 match stylized_file ( path, file_text) {
769769 Ok ( s) => return s,
770770 Err ( err) => {
0 commit comments