isDir
isDir(S_name[tl_path] ) =>t/nil
Description
Checks if a path exists and if it is a directory name.
When S_name is a relative path, the current SKILL path is used if it’s non-nil. A path that is anchored to the current directory, for example, ./, ../, or ../../.., and so on, is not considered as a relative path.
Arguments
Value Returned
|
The name exists and is not the name of a directory or S_name does not exist at all. |
Examples
Assumes DACLib is a directory and triadc is a file under the current working directory and the SKILL path is nil.
isDir("DACLib")
=> t
isDir("triadc")
=> nil
The following example returns nil if test does not exist.
isDir("test")
=> nil
Related Topics
Return to top