fs.isDir
Returns true
if a directory exists at path path. Returns false
if path path is a file, or if it does not exist.
|
|||
Creates the directory foo , checking if it is a directory before and after. |
|||
Code | <nowiki>
print("Foo is directory:", fs.isDir("foo"))
print("Making foo")
fs.makeDir("foo")
print("Foo is directory:", fs.isDir("foo"))
</nowiki>
|
||
Output | <nowiki>
Foo is directory: false
Making foo
Foo is directory: true
</nowiki>
|
Functions | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Lua |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
CC:Tweaked |
|
fs.isDir Function | |
---|---|
Syntax fs.isDir(
| |
Returns | boolean |
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.