Skip to content

[task] Resolve current GitHub repository #5

@phongndo

Description

@phongndo

Goal

Resolve the current GitHub repository from a local checkout so app-server methods know which repository they are reading.

Why this matters

TUI and desktop views need a clear repository context before showing issues, PRs, checks, and reviews. Nexgit should make the target explicit instead of relying on ambiguous defaults.

Command/API target

Add shared logic that can identify OWNER/REPO from the current working directory and Git remotes, with GitHub as the only MVP provider.

Depends on

Out of scope

  • Do not support GitLab, Codeberg, or Forgejo yet.
  • Do not implement write-target safety or mutation prompts here.
  • Do not add TUI or desktop rendering in this issue.

Definition of done

  • A GitHub remote resolves to an OWNER/REPO value.
  • Missing, non-GitHub, and ambiguous remotes produce understandable errors.
  • The behavior is reusable by app-server methods.

Verification

  • cargo fmt --all --check
  • cargo check --workspace
  • Tests cover GitHub remote, no remote, and unsupported remote cases.

Contributor notes

Keep this narrow. This is repository identity only, not issue or PR lookup.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: coreShared Rust product logic and domain behavior.help wantedMaintainers would welcome a community contribution on this work.kind: featureA user-facing capability request.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions