acidbase.file_depth

acidbase.file_depth(path: str | Path) int

Return the directory depth of path.

Parameters:

path (str or Path) – File or directory path.

Returns:

Number of path components after the root.

Return type:

int