Skip to content

Commit

Permalink
fix: build script new line at eof (#3353)
Browse files Browse the repository at this point in the history
When generating the build script, it will
fail `cargo fmt -- --check` because it is
missing a new line at the end of the file.
  • Loading branch information
Zarthus authored Jul 19, 2024
1 parent 4683cc3 commit 543395d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sqlx-cli/src/migrate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,8 @@ pub fn build_script(migration_source: &str, force: bool) -> anyhow::Result<()> {
fn main() {{
// trigger recompilation when a new migration is added
println!("cargo:rerun-if-changed={migration_source}");
}}"#,
}}
"#,
);

fs::write("build.rs", contents)?;
Expand Down

0 comments on commit 543395d

Please sign in to comment.