> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# Filesystem

> 读取、写入和管理文件和文件夹。

<div className="real-category-page">
  读取、写入和管理文件和文件夹。

  ## 可用函数

  <CardGroup cols={2}>
    <Card title="appendfile" href="./appendfile">
      Appends raw Lua string bytes to a workspace file using binary append mode. The file may be created if its parent folder exists.
    </Card>

    <Card title="delfile" href="./delfile">
      删除 workspace 内已存在的 regular file。
    </Card>

    <Card title="delfolder" href="./delfolder">
      使用 recursive folder deletion 递归删除 workspace 内已存在的 folder。
    </Card>

    <Card title="getcustomasset" href="./getcustomasset">
      将已存在的 regular workspace file 复制到 ExtraContent/\<hwid>/，并为复制后的 asset path 返回 rbxasset:// string。
    </Card>

    <Card title="isfile" href="./isfile">
      Returns whether a path resolved inside the workspace exists and is a regular file.
    </Card>

    <Card title="isfolder" href="./isfolder">
      Returns whether a path resolved inside the workspace exists and is a directory.
    </Card>

    <Card title="listfiles" href="./listfiles">
      Returns an array table of the direct children of an existing workspace directory.
    </Card>

    <Card title="loadfile" href="./loadfile">
      Reads a workspace file, compiles its contents with the Luau compiler, and returns the loaded Luau function without executing it.
    </Card>

    <Card title="makefolder" href="./makefolder">
      使用 recursive folder creation 在 workspace 内创建 directory，包括 missing parent directories。
    </Card>

    <Card title="openfiledialog" href="./openfiledialog">
      通过 Windows file picker 打开 Windows file-open dialog，并将所选文件作为 file item 返回。
    </Card>

    <Card title="openfilesdialog" href="./openfilesdialog">
      通过 Windows file picker 打开启用 multi-select 的 Windows file-open dialog，并将选中的文件作为 file item 值返回。
    </Card>

    <Card title="openfolderdialog" href="./openfolderdialog">
      通过 Windows file picker 和 folder selection mode 打开 Windows folder picker，并将选中的文件夹作为 file item 返回。
    </Card>

    <Card title="readfile" href="./readfile">
      以 binary mode 读取 workspace 内的 existing regular file，并将其 bytes 作为 Lua string 返回。
    </Card>

    <Card title="savefiledialog" href="./savefiledialog">
      通过 Windows save dialog 打开 Windows save dialog，将提供的 Lua string bytes 写入 selected path，并将 saved file 作为 file item 返回。
    </Card>

    <Card title="writefile" href="./writefile">
      将 Lua string bytes 写入 workspace 内的文件，创建 missing parent directories，并在文件已存在时替换 file contents。
    </Card>
  </CardGroup>
</div>
