on master help sign in
Added printing of "<BINARY>" for binary files in the interactive mode if header decorations are turned off
f37dbb8Maksim Panfilov
src/printer.rs+3
@@ -194,6 +194,9 @@ impl<'a> InteractivePrinter<'a> {
194impl<'a> Printer for InteractivePrinter<'a> {
194impl<'a> Printer for InteractivePrinter<'a> {
195 fn print_header(&mut self, handle: &mut Write, file: InputFile) -> Result<()> {
195 fn print_header(&mut self, handle: &mut Write, file: InputFile) -> Result<()> {
196 if !self.config.output_components.header() {
196 if !self.config.output_components.header() {
197+ if ContentType::BINARY == self.content_type {
198+ writeln!(handle, "<BINARY>")?;
199+ }
197 return Ok(());
200 return Ok(());
198 }
201 }
199
202