mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-10-07 03:00:29 +00:00
Make the full workspace nextest run reliable after the run-store migration, restore legacy test-harness projections needed by workflow integration tests, and clear the remaining fmt/clippy issues in the touched paths.
29 lines
981 B
Rust
29 lines
981 B
Rust
use std::path::PathBuf;
|
|
use std::process::Command;
|
|
|
|
fn main() {
|
|
println!("cargo:rerun-if-changed=../../../apps/fabro-web/app");
|
|
println!("cargo:rerun-if-changed=../../../apps/fabro-web/public");
|
|
println!("cargo:rerun-if-changed=../../../apps/fabro-web/scripts/build.ts");
|
|
println!("cargo:rerun-if-changed=../../../apps/fabro-web/index.template.html");
|
|
println!("cargo:rerun-if-changed=../../../apps/fabro-web/package.json");
|
|
|
|
let profile = std::env::var("PROFILE").unwrap_or_default();
|
|
if profile != "release" {
|
|
return;
|
|
}
|
|
|
|
let web_dir =
|
|
PathBuf::from(std::env::var("CARGO_MANIFEST_DIR").unwrap()).join("../../../apps/fabro-web");
|
|
|
|
let status = Command::new("bun")
|
|
.args(["run", "build"])
|
|
.current_dir(&web_dir)
|
|
.status()
|
|
.expect("failed to run `bun run build` for embedded web assets");
|
|
|
|
assert!(
|
|
status.success(),
|
|
"`bun run build` failed for embedded web assets"
|
|
);
|
|
}
|