You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
1.0 KiB
23 lines
1.0 KiB
|
|
use ts_rs::TS;
|
|
mod config;
|
|
|
|
fn main() {
|
|
tauri_build::build();
|
|
|
|
const OUT_PROCESSED: &'static str = "../data/processed_world_areas.json";
|
|
const OUT_PROCESSED_FULL: &'static str = "../data/processed_world_areas_full.json";
|
|
println!("cargo:rerun-if-changed=../data/WorldAreas.json");
|
|
poe_data::world_area::repack(&include_str!("../../data/WorldAreas.json"), OUT_PROCESSED);
|
|
poe_data::world_area::repack_full(&include_str!("../../data/WorldAreas.json"), OUT_PROCESSED_FULL);
|
|
|
|
//Let's go with uppercase names, allows automatic import to work...
|
|
config::Rect::export_to("../src/app/_models/generated/Rect.ts").expect("Could not generate config struct");
|
|
config::Config::export_to("../src/app/_models/generated/Config.ts").expect("Could not generate config struct");
|
|
println!("cargo:rerun-if-changed=src/config.rs");
|
|
println!("cargo:rerun-if-changed=../src/app/_models/generated/Rect.ts");
|
|
println!("cargo:rerun-if-changed=../src/app/_models/generated/Config.ts");
|
|
|
|
println!("cargo:rustc-cfg=build_only");
|
|
}
|