fs.getSize
Returns the size of a file in Bytes. Returns 0 if path is a directory.
|
|||
| Print the Size of "/rom/programs/edit.lua" in Bytes. | |||
| Code | <nowiki>
print(fs.getSize("/rom/programs/edit.lua"))
</nowiki>
|
||
| Output | 22975
|
||
Functions | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Lua |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| CC:Tweaked |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| fs.getSize Function | |
|---|---|
|
Syntax fs.getSize(
| |
| Returns | number |
| API | fs |
| Source | CC:Tweaked (source) |
This article is issued from Computercraft. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.