Concise manifest DSL for checked-in generated files.
Use rust/2 when a target is a list of RustQ AST items and generate/2
with content/1 for arbitrary generated content:
use RustQ.Config
alias RustQ.Rustler.Term
rust "native/my_nif/src/generated_term_helpers.rs" do
Term.helpers()
end
generate "lib/my_app/native/generated_stubs.ex" do
content(MyApp.Codegen.Native.stubs())
endRun mix rustq.gen to write targets and mix rustq.gen --check in CI.
Summary
Functions
Sets a custom zero-arity build function for the current generate target.
Sets content for the current generate target.
Declares an arbitrary generated target, inferring its name from the path.
Declares an arbitrary generated target with an explicit name.
Requires a generator source file once and returns the current manifest.
Declares a generated Rust item target, inferring its name from the path.
Declares a generated Rust item target with an explicit name.
Functions
Sets a custom zero-arity build function for the current generate target.
Sets content for the current generate target.
Declares an arbitrary generated target, inferring its name from the path.
Declares an arbitrary generated target with an explicit name.
Requires a generator source file once and returns the current manifest.
Declares a generated Rust item target, inferring its name from the path.
Declares a generated Rust item target with an explicit name.