Skip to content

Commit

Permalink
Update README examples
Browse files Browse the repository at this point in the history
  • Loading branch information
Ploppz committed May 14, 2022
1 parent be183d4 commit c587c38
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use file_rotate::{FileRotate, ContentLimit, suffix::AppendCount};
use std::{fs, io::Write, path::PathBuf};

fn main() {
let mut log = FileRotate::new("logs/log", AppendCount::new(2), ContentLimit::Lines(3));
let mut log = FileRotate::new("logs/log", AppendCount::new(2), ContentLimit::Lines(3), None);

// Write a bunch of lines
writeln!(log, "Line 1: Hello World!");
Expand Down Expand Up @@ -48,6 +48,7 @@ let mut log = FileRotate::new(
"logs/log",
AppendTimestamp::default(FileLimit::MaxFiles(3)),
ContentLimit::Lines(3),
None,
);

// Write a bunch of lines
Expand Down

0 comments on commit c587c38

Please sign in to comment.