Splits history-ui out of asch/fix-everything into its own branch off main. Includes the Svelte workspace, the three dedicated server endpoints (list_vaults, fetch_vault_history, fetch_document_versions), SPA asset embedding via rust-embed, and the matching TS mirror types in sync-client. Note: this branch will not compile against main on its own — the new endpoints depend on database/error/config additions that live on asch/fix-everything. Intended to be merged once asch/fix-everything lands. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
16 lines
710 B
Rust
16 lines
710 B
Rust
fn main() {
|
|
// trigger recompilation when a new migration is added
|
|
println!("cargo:rerun-if-changed=migrations");
|
|
|
|
// Ensure the history-ui dist directory exists so rust-embed can compile
|
|
// even when the frontend hasn't been built yet.
|
|
let dist_path = std::path::Path::new("../frontend/history-ui/dist");
|
|
if !dist_path.exists() {
|
|
std::fs::create_dir_all(dist_path).expect("Failed to create history-ui dist directory");
|
|
std::fs::write(
|
|
dist_path.join("index.html"),
|
|
"<!DOCTYPE html><html><body><p>Run <code>npm run build -w history-ui</code> first.</p></body></html>",
|
|
)
|
|
.expect("Failed to write placeholder index.html");
|
|
}
|
|
}
|