def find_integrations(root_path: Path, recursive=False) -> list[Path]:
    """Find all integrations packages in the repo."""
    package_roots: list[Path] = []
    integrations_root = root_path
    if not recursive:
        integrations_root = integrations_root / "llama-index-integrations"

    for category_path in integrations_root.iterdir():
        if not category_path.is_dir():
            continue

        if category_path.name == "storage":
            # The "storage" category has sub-folders
            package_roots += find_integrations(category_path, recursive=True)
            continue

        for package_name in category_path.iterdir():
            if is_llama_index_package(package_name):
                package_roots.append(package_name)

    return package_roots
Find all integrations packages in the repo.
llama-dev/llama_dev/utils.py