Skip to content

Commit 9cd9aa4

Browse files
abonandermehcode
authored andcommitted
cargo sqlx prepare: delete query-*.json files as they're read
1 parent 01c1f80 commit 9cd9aa4

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

sqlx-cli/src/prepare.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,9 @@ fn run_prepare_step(cargo_args: Vec<String>) -> anyhow::Result<QueryData> {
121121
path.display()
122122
)
123123
}
124+
125+
// lazily remove the file, we don't care too much if we can't
126+
let _ = fs::remove_file(&path);
124127
}
125128

126129
Ok(data)

0 commit comments

Comments
 (0)