Skip to content

$folder

Hawkmax edited this page Mar 15, 2026 · 3 revisions

Description

The $folder command reads all JSON files from a given folder and assigns them to the specified member.
For further reference, see also the helper function readRichJsonDirectory.

Syntax

member: { "key": "$folder:<path>" }
key: no implementation

Param(s)

path: Defines the path to a folder, e.g. my/path/to/folder. The path must be absolute, starting from the datafiles folder inside your project directory.

Example

Before Apply

{ // <-- root
    // In the line below, the `$folder` command will read all JSON files from the folder named `skins`
    "ref_folder": "$folder:path/to/folder"
}

After Apply

{
    "ref_folder": {
        "some_folder": _content of the folder_,
        "some_json_file0": _content of the JSON file_,
        "some_json_file1": _content of the JSON file_
    }
}

Author’s Recommendation: next read $merge

Clone this wiki locally