Skip to content

Commit

Permalink
Don’t rebuild library when tests changes.
Browse files Browse the repository at this point in the history
Cargo’s default is to re-run build scripts (and therefore rebuild stuff)
whenever any file changes.
We can be more precise.
  • Loading branch information
SimonSapin committed Jan 25, 2016
1 parent 13a554e commit 996fff2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@ fn main() {

named_entities_to_phf(
&Path::new(&manifest_dir).join("data/entities.json"),
&Path::new(&env::var("OUT_DIR").unwrap()).join("named_entities.rs"))
&Path::new(&env::var("OUT_DIR").unwrap()).join("named_entities.rs"));

println!("cargo:rerun-if-changed={}", rules_rs.display());
}

#[cfg(feature = "codegen")]
Expand Down

0 comments on commit 996fff2

Please sign in to comment.