Hive
feat(frontend,cli): fabrik.star loader, workspace walk, glob, and fabrik build
GitHub issue · Closed
Source
tuist/once #8
Updated
Jun 24, 2026
Domains
Once
Summary
- New
fabrik-frontendcrate embedsstarlark-rust0.13. Built-in target globals:rust_binary,rust_library,rust_test, plus aglob()primitive that expands relative to the package directory. load_workspacerecursively walks the workspace forfabrik.starfiles (skipping hidden directories like.gitand the.fabrik/cache) and labels every target as//pkg:name.fabrik targetslists every declared target across the workspace;fabrik build <label>emits arustcaction forrust_binary, runs it through the existing action cache, and writes the binary to.fabrik/out/<package>/<name>with cache hits on repeat invocations.- Standardize on
fabrik.star(per package) and*.star(plugin/SDK modules) as the build-file convention. The.fabrik/cache directory keeps its project-branded name. AGENTS.mdcaptures repo-wide conventions: avoid monolith Rust files (top-level reads as a TOC), build-file naming, no em dashes in user-facing text, no roadmap-phase references in code, and themise exec --invocation pattern.
Known follow-ups (not in this PR)
- Cache key does not include source file content.
Action::RunCommand’s digest isargv + env + cwd + timeoutonly. Editing asrc/*.rsfile and re-runningfabrik buildcurrently serves a stale cache hit. The next PR should add declaredinputs: Vec<WorkspacePath>toActionand digest their content into the key. rust_libraryandrust_testdeclare but don’t build (fabrik build //x:liberrors with “not yet supported”).rust_binaryignoresdeps; no--externplumbing yet, so cross-crate builds and any crate using external dependencies (anything in this repo) won’t compile.- Cache key includes machine
PATHandHOMEso it’s not portable across machines. Hermetic toolchain handling is later work. - Only the first
srcsentry is treated as the crate root; multi-file binaries with a separatecrate_rootneed a follow-up.
Testing
mise exec -- cargo test --workspace(all green; 10 new frontend unit tests)mise exec -- cargo clippy --workspace --all-targets -- -D warnings(clean)mise exec -- cargo fmt --all -- --check(clean)mise exec -- shellspec(39/39 examples; 11 new underspec/build_spec.shandspec/targets_spec.sh)- Manual end-to-end: scaffolded a hello-world workspace, ran
fabrik build //hello:hello, executed the resulting binary, re-ran to confirm cache hit.
Investigate, reproduce, or fix this item in an isolated repository. Each Flight preserves its outcome and agent session.
New Flights are paused
Configure model inference, GitHub, and a sandbox provider to start another Flight. Existing results remain available below.
No Flights yet
Start a Flight and preserve its objective, outcome, and session here.
No GitHub comments yet.