Configuration Reference
Tungsten is configured through a tungsten.toml file in your project’s root directory. Run tungsten init to generate one, or create it manually.
Full example
Section titled “Full example”Fields
Section titled “Fields”[creator]
Section titled “[creator]”Defines which Roblox account or group assets are uploaded under.
| Field | Type | Description |
|---|---|---|
type | "user" or "group" | Whether to upload under a user or a group, defaults to "user". |
id | number | The Roblox user or group ID to upload under. |
[codegen]
Section titled “[codegen]”Controls how Tungsten generates your Luau output files.
| Field | Type | Description |
|---|---|---|
style | "flat" or "nested" | The structure of the generated Luau table, defaults to "flat". |
strip_extension | boolean | Whether to strip the file extension from asset keys, defaults to false. |
ts_declaration | boolean | Whether to generate a TypeScript definition file, defaults to false. |
[inputs.<name>]
Section titled “[inputs.<name>]”Defines a set of assets to sync. You can define as many input blocks as you need — each one is identified by its name (e.g. [inputs.packed_assets]).
| Field | Type | Description |
|---|---|---|
path | string | A glob pattern pointing to the assets to sync. |
output_path | string | Where Tungsten writes the generated Luau file. |
packable | boolean | Whether to pack matched assets into a spritesheet before uploading. |
svg_scale | number | (Optional) Multiplier for SVG rasterization, defaults to 1.0. |
[inputs.<name>.compress_options]
Section titled “[inputs.<name>.compress_options]”Enables and configures image optimization for a specific input group. When this table is present, Tungsten uses libcaesium to reduce the file size of your images before they are uploaded to Roblox.
| Field | Type | Description |
|---|---|---|
jpeg_quality | number | Quality of the JPEG image (0-100), defaults to 80. |
png_quality | number | Quality of the PNG image (0-100), defaults to 80. |
keep_metadata | boolean | Whether to keep metadata in the compressed image, defaults to true. |