Once
Once makes project scripts cacheable, observable, and remotely executable. Declare the inputs, outputs, environment, and runtime contract once, then reuse the result locally, in CI, or on a compute provider.
Quick Start
Describe a script with # once annotations:
#!/usr/bin/env bash
# once input "../assets/**/*"
# once output "../dist/"
# once cwd ".."
npm run build-assetsRun it through the cache:
once exec -- bash scripts/build-assets.sh
once exec --remote --compute microsandbox -- bash scripts/build-assets.shScripts can also run directly with a Once shebang:
#!/usr/bin/env -S once exec -- bashDocumentation
Read the documentation at once.tuist.dev.
Integrations
Use the once crate when embedding Once in Rust applications:
[dependencies]
once = { git = "https://github.com/tuist/once" }Release builds also publish Once.xcframework.zip for Apple platforms.
The framework exposes a small C ABI that Swift and Objective-C can call,
with JSON requests and responses for cache access.
License
MIT.
