[generate] & [project]

The [generate] and [project] tables — schema path, output directory, targets, and project metadata.

The [generate] table controls what forgedb generate reads and emits; [project] carries plain metadata. Both are read at generate time.

[generate]#

[generate]
schema = "schema.forge"
output = "./generated"
targets = ["rust", "typescript", "api", "stubs"]
KeyTypeDefaultMeaning
schemastring"schema.forge"Path to the .forge schema file to transpile.
outputstring"./generated"Output directory for generated files.
targetsstring[](all targets)Which targets to emit. When absent, all are enabled.

Valid targets values: rust, typescript, api, openapi, stubs, plus the opt-in wasm (browser read-replica) and ffi (C-ABI engine). When the key is absent, the default set rust, typescript, api, openapi, stubs is generated. wasm and ffi emit only when listed explicitly.

CLI flags override these

--schema and --output on the forgedb generate command take precedence over the [generate] values, which in turn take precedence over the built-in defaults. See configuration precedence.

[project]#

[project]
name = "my-app"
version = "0.1.0"
KeyTypeDefaultMeaning
namestring(unset)Project name (metadata).
versionstring(unset)Project version (metadata).

[project] is metadata only; it does not affect generated code. forgedb init emits it and the generator ignores it. Unknown tables are ignored too, which keeps the config forward-compatible.

Search documentation

Find pages across the ForgeDB docs