Skip to content

[Feature] Add Forgejo source provider (v1) with repo-scoped search and required URL #61

@mbe24

Description

@mbe24

Problem

99problems currently supports GitHub, GitLab, Jira, and Bitbucket, but not Forgejo.

Users on Forgejo instances cannot use get for issue/PR context retrieval, which blocks adoption in self-hosted and Forgejo-centric environments.

Design

Implement Forgejo provider v1 with balanced parity:

  1. search + ID fetch for issues and pull requests,
  2. issue comments + PR review comments,
  3. link hydration from timeline/dependencies/blocks.

Locked v1 boundaries:

  1. Forgejo URL is required (--url or instance url),
  2. search is repo-scoped only (repo:owner/repo / --repo required),
  3. instance-wide cross-repo search is deferred.

Scope

  • Add new source adapter under src/source/forgejo/.
  • Wire platform selection and source construction for forgejo.
  • Add FORGEJO_TOKEN env support in config/token resolution.
  • Implement repo-scoped search mapping and ID fetch endpoints.
  • Implement comments/review-comments/link hydration with parallelized branches.
  • Update docs/examples (README/config/skill provider listings).

Boundary

  • No cross-repo Forgejo search in this issue.
  • No gitea alias in this phase.
  • No behavior change for existing providers.

Acceptance Criteria

  • 99problems get --platform forgejo --url <forgejo-base> --repo owner/repo -q "..." works.
  • 99problems get --platform forgejo --url <forgejo-base> --repo owner/repo --id <n> --type issue|pr works.
  • Issue comments and PR review comments are returned according to flags.
  • Link metadata is hydrated best-effort from Forgejo timeline/dependency/blocking APIs.
  • Missing Forgejo URL returns clear usage guidance.
  • Existing provider tests remain green.

Context

Forgejo exposes compatible issue/PR APIs and review/timeline/dependency endpoints, making a focused v1 adapter feasible without broad architectural changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions