Trigger rebuild on STRINGS_JSON change

This commit is contained in:
Damien Elmes 2023-02-17 19:03:33 +10:00
parent ab8b1465d4
commit e9385d2999

View File

@ -23,6 +23,7 @@ fn main() {
write_strings(&map, &modules);
// write strings.json file to requested path
println!("cargo:rerun-if-env-changed=STRINGS_JSON");
if let Some(path) = option_env!("STRINGS_JSON") {
let meta_json = serde_json::to_string_pretty(&modules).unwrap();
fs::write(path, meta_json).unwrap();