Lua IO library extension.
More...
◆ io.crc32()
| number io.crc32 |
( |
string | string | ) |
|
Gets the CRC32 hash of a string
◆ io.delete()
| nil io.delete |
( |
string | path | ) |
|
Deletes a file or a folder
◆ io.editsfo()
| nil io.editsfo |
( |
string | path | ) |
|
Edits a parameter in a .SFO file
◆ io.exists()
| boolean io.exists |
( |
string | path | ) |
|
Checks if a file or folder exists or not
◆ io.filestrip()
| string io.filestrip |
( |
string | path | ) |
|
Strips the last file/directory from a path
◆ io.freespace()
| number io.freespace |
( |
string | partition | ) |
|
Gets the free space of a partition
◆ io.info()
| table io.info |
( |
string | path | ) |
|
Lists information about a file or a folder.
- Returns
- A table with these fields:
- "accessed": string
- "modified": string
- "created": string
- "isafolder": boolean
- "size": number (size represented in bytes)
◆ io.list()
| table io.list |
( |
string | path | ) |
|
Lists a directory
- Returns
- A list of tables that represent the contents with these fields:
- "name": string
- "path": string
- "isafolder": boolean
- "created": string
- "modified": string
- "accessed": string
- "size": number (size represented as bytes)
◆ io.md5()
| string io.md5 |
( |
string | string | ) |
|
Gets the MD5 hash of a string
◆ io.newfolder()
| nil io.newfolder |
( |
string | path | ) |
|
◆ io.pathstrip()
| string io.pathstrip |
( |
string | path | ) |
|
Strips the files/directories from a path besides the last one
◆ io.readsfo()
| table io.readsfo |
( |
string | path | ) |
|
Reads a .SFO file
- Returns
- A table with the keys & values of the .SFO
◆ io.sha1()
| string io.sha1 |
( |
string | string | ) |
|
Gets the SHA1 hash of a string
◆ io.sha256()
| string io.sha256 |
( |
string | string | ) |
|
Gets the SHA256 hash of a string
◆ io.totalspace()
| number io.totalspace |
( |
string | partition | ) |
|
Gets the size of a partition
◆ io.workpath()
| nil or string io.workpath |
( |
string | path | ) |
|
- Parameters
-
| path | optional, if empty it'll return the current workpath, otherwise it'll set the workpath to the specified path |