How can I check if a file exists using Lua?
相关问题
- How to get the return code of a shell script in lu
- Lazily Reading a File in D
- Check whether the path exists on server or not in
- Accessing Light userdata in Lua
- DirectoryStream.Filter example for listing files t
相关文章
- How to replace file-access references for a module
- Why is file_get_contents faster than memcache_get?
- Transactionally writing files in Node.js
- Getting the cluster size of a hard drive (through
- Example for file read/write with NSFileHandle
- Lua Integer type
- line-by-line file processing, for-loop vs with
- First character uppercase Lua
Looks good for testing your way. :)
You can also use the 'paths' package. Here's the link to the package
Then in Lua do:
An answer which is windows only checks for files and folders, and also requires no additional packages. It returns
true
orfalse
.