Mojo function
isdir
isdir[PathLike: PathLike, //](path: PathLike) -> Bool
Return True if path is an existing directory. This follows symbolic links, so both islink() and isdir() can be true for the same path.
Parameters:
- PathLike (
PathLike): The type conforming to the os.PathLike trait.
Args:
- path (
PathLike): The path to the directory.
Returns:
Bool: True if the path is a directory or a link to a directory and
False otherwise.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!