feat(gitlab): support repositories, sign-in and cloud workspaces

TE
2mo ago
+96609-1739

What & why

Add native GitLab repository, issue and merge-request workflows across desktop and iOS, optional GitLab sign-in, organization connections, project-scoped automation and cloud environments/checkouts. GitLab.com and configured instances use provider/host/project-bound identities; existing GitHub and hosted defaults remain available.

  • Native cloud reads and writes use the existing signed, project-bound credential broker. Tokens stay server-side. Explicit review-search routes and bounded plain-text job traces are supported; fork CI/log reads prove the selected MR’s source project, exact head and pipeline/job membership.
  • Native detail, diff, body, comment, merge, ready and create actions retain the full selected identity. The latest upstream desktop ship controls send the native provider/context and reject retained callbacks after workspace or MR changes. A late create toast opens the original workspace.
  • Native Git 4 tasks receive the resolved environment at client construction, so credential and Git settings pass through the existing environment guard during resolve, push and raw execution.
  • Issue prompt context keeps its verified source when the destination changes. Lost/reset/failed/partial bound delivery recovers the canonical workspace through a bounded read and blocks whole-create replay, preventing duplicate agent prompts.
  • Automation requires explicit nonempty project selection, validates event-specific filters and serializes complete hook reconciliation per connection. Capability reads batch large project lists; bounded caches and background refresh preserve usable selection.
  • Mobile exposes projects with no workspaces, preserves cross-provider links and wraps environment names. Optional sign-in scrolls, and provider actions share the Apple-capability configuration. Native labels, body fetches, icons and action spinners use provider-aware copy translated in all 17 locales.

Land #8232 before enabling GitLab cloud operations. This feature retains the matching declarations without generated migration SQL. When composing #8237, register GitLab hook reconciliation in the native scheduler. Disable optional GitLab/application behavior first for rollback and retain additive metadata. This supersedes temporaryfix’s older #5353 proposal; it uses additive GitLab metadata rather than switching GitHub reads to generalized replacement tables.

One commit based on upstream 2dda82c314606aaa099b8626150c61450d66b629. Final candidate: a3772393fa9f89b93f9965dac6a8b3a4c88b4b4a. Related review: tracking issue #8241.

The one-commit combined source on review/verified-composition-20261007 (ef1ac91f) integrates all seven proposals for reproduction without another PR. Shared graph evidence applies to that composition; focused proposal checks are recorded separately.

How I tested it

The completion ledger disposes all 63 GitLab/schema findings with regression proof or an explicit duplicate/disproved disposition. Fixtures execute selected-project/fork broker authorization, trace bounds, simultaneous hook reconciliation, Local→Cloud issue context, uncertain canonical recovery without replay, partial launches, large project batches, stale callbacks and cached background errors. The refreshed desktop controls passed 20 actual React/transport cases and a 68-test surrounding suite.

Real Git environment regressions passed 102 isolated task/project/MR-dispatch/binding cases. The corrected tRPC fixture passed all 36 actual create/update/promote caller cases and 187 assertions. Combined mobile fixtures exercise the real quiet wrapper; fresh disabled/unknown selections make no environment request and expose no ready native selection.

A production-defined host worker ran under Node 22 against disposable physical Git repositories with network and dotenv reads denied. It verified event-loop responsiveness, common-storage identity, quarantine after uncertain dispatched mutation and prevention of replay across replacement pools. Database acceptance is recorded in #8232. Final focused proposal checks: Final combined graph: all 42 compiler/declaration/catalog tasks passed; full lint passed 9,927 files. Current changed-test suites: API 185, desktop 290, mobile 102, host 696 and tRPC 399 passed with zero unresolved failures. Node 22 production-worker isolation and installed glab credential forwarding ran; actual canonical DB fixtures passed with zero skips. The source-only composition linked in #8241 reproduces shared auth/configuration contracts..

24 original app captures and review evidence. Capture and external-check provenance is recorded once in #8241.

Checklist

  • PR title follows conventional commits (type(scope): subject)
  • bun run lint and bun run typecheck pass (final candidate scope/results above)
  • "Allow edits from maintainers" is checked on fork PRs