Skip to content

Commit

Permalink
chore: repair clippy lint
Browse files Browse the repository at this point in the history
Clippy recommends adding the explicit truncate on this file creation.
  • Loading branch information
jpgrayson committed Apr 1, 2024
1 parent 4d15274 commit 0e50399
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/cmd/export.rs
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,7 @@ fn run(matches: &clap::ArgMatches) -> Result<()> {
let mut file = std::fs::File::options()
.write(true)
.create(true)
.truncate(true)
.open(output_dir.join(&patchfile_name))
.with_context(|| format!("opening {patchfile_name}"))?;
file.write_all(&specialized)?;
Expand Down

0 comments on commit 0e50399

Please sign in to comment.