Skip to main content

max / makeover-build

1.8 KB · 51 lines History Blame Raw
1 # makeover-build
2
3 Build-script support for the make-family design system.
4
5 Every consumer materialises the same generated files from a `build.rs`. This is
6 that code, once, so no consumer keeps its own copy.
7
8 ```rust
9 // build.rs
10 fn main() {
11 makeover_build::tauri_frontend(env!("CARGO_MANIFEST_DIR"), &makeover_build::Emit::default());
12 tauri_build::build();
13 }
14 ```
15
16 That writes `themes/` beside the manifest and `frontend/css/layout.css` under
17 it, which is where both Tauri apps already look. Consumers wanting different
18 paths call `themes` and `layout_css` directly.
19
20 ## What is deliberately not here
21
22 The geometry emitter. GoingsOn scopes the touch preset to a `ui-mode-mobile`
23 class set by a bootstrap script, Balanced Breakfast hangs it off
24 `@media (hover: none)`, and audiofiles has no switch at all. Extracting it would
25 mean picking one of those policies by accident, inside a shared crate, without
26 anyone deciding. Density selection is unowned and has its own task; the geometry
27 half lands after it.
28
29 Taking the identical half now and leaving the contested half alone is the point.
30 A helper crate should record agreement, not manufacture it.
31
32 ## Why these files are generated
33
34 Tauri's resource globs are read by its CLI against the crate directory, so they
35 cannot point into a registry checkout or `OUT_DIR`. Materialising into the crate
36 keeps the source crate authoritative without vendoring a second copy that
37 drifts. Every path written here is expected to be gitignored.
38
39 `themes` clears stale `.toml` files before writing, so a theme removed or
40 renamed upstream does not linger in the bundle from a previous build. Omitting
41 that step shows up as a theme that will not go away.
42
43 ## Status
44
45 Unpublished, path deps on `makeover` and `makeover-webview`. Consumers are
46 GoingsOn and Balanced Breakfast.
47
48 ## Licence
49
50 MIT.
51