Files
gemini-cli/plans/TASK-10.md
Taylor Mullen 19b9e3e8e4 feat(agents): implement team registry client and installation service
- Add RegistryTeam interface and TeamRegistryClient for remote/local discovery.
- Enhance TeamScaffolder with installRegistryTeam supporting Git and metadata-only teams.
- Refactor GitHub/Git utilities from cli to core for shared usage.
- Add comprehensive unit tests for new services.

TASK-09, TASK-10
2026-04-06 16:20:00 -07:00

1.2 KiB

TASK-10: Team Installation and Scaffolding Service

Objective

Enhance the TeamScaffolder service to handle installing teams from a RegistryTeam definition, including support for definitions with only metadata or full Git-based teams.

Implementation Details

1. Scaffolder Enhancements (packages/core/src/agents/teamScaffolder.ts)

  • Implement installRegistryTeam(team: RegistryTeam):
    • Validates the team definition.
    • If sourceUrl is provided (e.g., a GitHub link), handle cloning/downloading:
      • Reuse logic from ExtensionManager (cloneFromGit, downloadFromGitHubRelease).
      • Copy the contents to .gemini/teams/<team-name>/.
    • If only prompt/metadata are provided in the RegistryTeam JSON:
      • Scaffold the directory structure.
      • Generate TEAM.md.
      • Generate corresponding .md agent files in the agents/ folder (especially for external kind agents).

2. Registry Update

  • Ensure the TeamRegistry is notified to reload discovered teams after a successful installation.

Verification

  • Unit tests for installRegistryTeam with both "Definition only" and "Full Git-based" team mocks.
  • Verify that a successfully installed team appears in the discovered teams list.