gigl.common.utils.list_at_path#

gigl.common.utils.local_fs.list_at_path(local_path: LocalUri, *, regex: str | None = None, file_system_entity: FileSystemEntity | None = None, names_only: bool = False) List[LocalUri]#

List all files and directories in the given local path.

Args:

local_path (LocalUri): The local path to search for files and directories. regex (Optional[str]): Optional regex to match. If not provided then all children will be returned. entity (Optional[FileSystemEntity]): Optional entity type to filter by. If not provided then all children will be returned. names_only (bool): If True, return only the base names of the files and directories. Defaults to False. e.g /path/to/file.txt -> file.txt

Returns:

List[LocalUri]: A list of local URIs for the files and directories in the given path.