πŸ“‚Filesystem

filesystem namespace

Functions

read

fs.read("some_file.txt")

path

string

path to file

Returns:

data

string

read_stream

fs.read_stream("some_file.txt")

path

string

path to file

Returns:

data

table of char

write

path

string

path to file

data

string

data to write to file

write_stream

path

string

path to file

data

table of char

data in bytes to write to file

remove

path

string

path to file

exists

path

string

path to file or directory

Returns:

true if file exists

boolean

is_file

path

string

path to file

Returns:

true if path leads to a file

boolean

is_dir

path

string

path to directory

Returns:

true if path leads to a directory

boolean

create_dir

path

string

path to directory

Last updated