2020-04-10 09:27:53 +00:00
|
|
|
--- The FS API allows you to manipulate files and the filesystem.
|
|
|
|
--
|
|
|
|
-- @module fs
|
|
|
|
|
2020-05-12 10:32:48 +00:00
|
|
|
--- Returns true if a path is mounted to the parent filesystem.
|
|
|
|
--
|
|
|
|
-- The root filesystem "/" is considered a mount, along with disk folders and
|
|
|
|
-- the rom folder. Other programs (such as network shares) can exstend this to
|
|
|
|
-- make other mount types by correctly assigning their return value for getDrive.
|
|
|
|
--
|
|
|
|
-- @tparam string path The path to check.
|
|
|
|
-- @treturn boolean If the path is mounted, rather than a normal file/folder.
|
|
|
|
-- @throws If the path does not exist.
|
|
|
|
-- @see getDrive
|
2021-08-26 07:02:58 +00:00
|
|
|
-- @since 1.87.0
|
2020-05-12 10:32:48 +00:00
|
|
|
function isDriveRoot(path) end
|
|
|
|
|
2020-07-09 20:59:19 +00:00
|
|
|
--[[- Provides completion for a file or directory name, suitable for use with
|
2020-11-12 19:40:18 +00:00
|
|
|
@{_G.read}.
|
2020-04-28 08:42:34 +00:00
|
|
|
|
2020-07-09 20:59:19 +00:00
|
|
|
When a directory is a possible candidate for completion, two entries are
|
|
|
|
included - one with a trailing slash (indicating that entries within this
|
|
|
|
directory exist) and one without it (meaning this entry is an immediate
|
|
|
|
completion candidate). `include_dirs` can be set to @{false} to only include
|
|
|
|
those with a trailing slash.
|
2020-04-10 09:27:53 +00:00
|
|
|
|
2020-07-09 20:59:19 +00:00
|
|
|
@tparam string path The path to complete.
|
|
|
|
@tparam string location The location where paths are resolved from.
|
|
|
|
@tparam[opt] boolean include_files When @{false}, only directories will be
|
|
|
|
included in the returned list.
|
|
|
|
@tparam[opt] boolean include_dirs When @{false}, "raw" directories will not be
|
|
|
|
included in the returned list.
|
|
|
|
@treturn { string... } A list of possible completion candidates.
|
2021-08-26 07:02:58 +00:00
|
|
|
@since 1.74
|
2020-07-09 20:59:19 +00:00
|
|
|
]]
|
|
|
|
function complete(path, location, include_files, include_dirs) end
|