JustZoe101 b810292b1f feat(phase5): inline review comments, credentials write, deploy keys, org create, profile edit
- inline (line-level) review comments: list per review + reply API/hook,
  rendered under each review on the PR detail screen
- credentials: SSH key/GPG key/token create+delete endpoints and hooks;
  deploy keys (repo keys) management screen
- user profile edit (GET/PATCH /user/settings) screen
- organization creation screen; wired into Settings and Organizations
- endpoints.test.ts extended to 120 tests
2026-10-09 18:16:51 +02:00

Gitea Native

An unofficial, open-source Gitea client for iOS and Android, built with React Native (Expo) and TypeScript.

Unofficial project. Gitea Native is not affiliated with, endorsed by, or connected to the Gitea project or Codeberg. "Gitea" and "Codeberg" are names and trademarks of their respective owners. This app talks to your Gitea instance using the public REST API.


What it does today

Gitea Native is a real, working client — not a prototype. The current build covers the read-heavy Git workflow:

  • Connect to any Gitea instance with a personal access token (PAT); the internet address is validated and remote instances must use HTTPS.
  • Multiple instances, multiple accounts per instance, with instant switching and account-isolated caches.
  • Biometric app lock (Face ID / Touch ID / Android biometrics) that also redacts the app-switcher snapshot.
  • Home dashboard with your identity, recent repositories, assigned issues, review requests, activity feed and an unread-notification badge.
  • Repository browsing: list/search your repositories (and starred ones), repository overview, topics, statistics and languages.
  • Files: directory navigation with breadcrumbs, common image previews, Markdown rendering and source file viewing.
  • History: paginated commit list, commit details with file changes, branches and tags.
  • Issues & pull requests: cross-repository lists (assigned, created, review-requested), per-repository lists, and detail screens with Markdown bodies, labels, assignees, milestones and reviewers.
  • Collaboration: comment threads with compose/edit/delete, create and edit issues, approve / request-changes / comment reviews, merge (squash or merge commit), a native unified diff viewer, and CI check statuses.
  • Quick Edit: edit a file in-app and commit it through the Contents API — to a branch or a new branch (protected branches are handled), optionally opening a pull request in the same step.
  • Repository actions: star/unstar, watch/unwatch, fork, plus releases and assets, and a configurable "Open in editor" action.
  • Notification inbox: unread/all filters, mark-as-read, mark-all-read, and life-cycle-aware polling.
  • English & Dutch, light/dark/system theme, accessible touch targets and loading/empty/error states throughout.

See docs/FEATURE_PARITY.md for the full matrix of what is implemented versus planned.

Technology

Concern Choice
Runtime Expo SDK 57, React Native 0.86, React 19
Language TypeScript (strict)
Navigation React Navigation 7 (native stack + bottom tabs)
Server state TanStack Query 5 (+ AsyncStorage persister for offline reads)
Client state Zustand 5
i18n i18next + react-i18next + expo-localization (en, nl)
Secure storage Expo SecureStore (Keychain / Android Keystore)
Biometrics expo-local-authentication
Lists Shopify FlashList 2
Markdown marked + a native renderer (no WebView)
Testing Jest (jest-expo) + @testing-library/react-native

Requirements

  • Node.js 20+ (developed on Node 24) and npm 10+.
  • A Gitea instance reachable over HTTPS (self-hosted or a public host such as gitea.com).
  • A personal access token created in Gitea under Settings → Applications → Manage access tokens. Read scopes (read:repository, read:issue, read:notification, …) are enough for everything implemented today.

Expo Go vs. development build

This project uses native modules (SecureStore, biometrics, expo-symbols, gesture handler, reanimated). They are all part of the Expo Go runtime or require a development build depending on the SDK. If anything native is missing, create a development build:

npx expo run:ios      # local build (needs Xcode)
npx expo run:android  # local build (needs Android Studio)
# or in the cloud:
bunx eas-cli build --profile development   # Bun projects
npx eas-cli@latest build --profile development

Getting started

# 1. Install dependencies
npm install

# 2. Start the dev server
npx expo start

Then press i (iOS simulator), a (Android emulator) or scan the QR code with a development build. Use npx expo start and open the app on a device/emulator with a dev build for the full feature set.

Configuration

There is no server URL or credential in the repository. Everything is entered at runtime and stored on-device:

  • The instance URL and PAT are collected on the Connect screen.
  • The PAT is written to SecureStore only (token.<accountId> under the gitea-native.credentials keychain service). It is never written to AsyncStorage, logs, or the account registry.
  • App metadata lives in app.json (name, slug, icons, splash, iOS/Android identifiers). There is no .env file to configure for normal use.

A small in-memory copy of the active token exists in the Zustand store so the API client can attach it to requests; it is deliberately excluded from all persistence paths.

Commands

Command Purpose
npm start Start the Expo dev server
npm run ios / npm run android Start for a specific platform
npm run typecheck tsc --noEmit
npm run lint ESLint (Expo config)
npm test Jest unit/component tests
npm run verify typecheck + lint + tests
npm run format Prettier write

Run npm run verify before opening a pull request.

Project structure

src/
  App.tsx                     # Providers + navigation container + app lock
  components/                 # UI kit, layout, and Git-specific components
  core/
    api/                      # HTTP client, endpoints, types, errors, query keys
    accounts/                 # registry (pure logic), token store, Zustand store
    security/                 # biometric helpers
    utils/                    # formatting, infinite-query helpers
  features/
    accounts/ auth/ home/ inbox/ issues/ notifications/
    repositories/ repository/  # feature folders: hooks + screens + components
  i18n/                       # i18next init + en/nl locales
  navigation/                 # navigators, typed param lists, linking, themes
  theme/                      # design tokens and theme provider

Feature folders keep non-screen code (hooks, helpers, components) outside screens/. Every navigator lives under src/navigation/.

Internationalization

All user-facing strings go through t() from react-i18next. The device language is detected with expo-localization; the user can override it in Settings (system, en, nl). New keys must be added to both src/i18n/locales/en.json and src/i18n/locales/nl.json; a test enforces key parity and matching interpolation placeholders.

Security

See docs/SECURITY.md for the full threat model. Summary:

  • Tokens only in the platform keystore (SecureStore).
  • HTTPS enforced for remote instances; embedded credentials rejected.
  • No secrets in logs, error messages, or crash reports.
  • Biometric lock protects the UI and blanks the app switcher snapshot.

Architecture

See docs/ARCHITECTURE.md for the navigation graph, state/data-flow, API client and account-registry design.

Roadmap

See ROADMAP.md. Phases 0–4 are complete; Phase 5 (advanced) is in progress — stars, watches, forks, releases, wiki and a capability probe are in, while orgs, Actions, packages and admin screens are planned.

Known limitations

  • The in-app editor is a native monospace field; syntax highlighting and search/replace (CodeMirror in a WebView) are planned.
  • Pull-request review comments are at the PR level; line-level (inline) review comments are planned.
  • Gitea Actions, packages, organizations and admin screens are not built yet.
  • Gitea's REST API exposes no total count for some endpoints, so infinite scroll falls back to a page-length heuristic.
  • Features that are unavailable or disabled on a given instance degrade to a clear empty/error state, or open in the browser where that is the only path (wiki). A version-based capability probe gates features without a server flag.

License

MIT © the Gitea Native contributors. See LICENSE. This is an independent project and is not derived from or endorsed by the Gitea project.

S
Description
No description provided
Readme MIT
843 KiB
0 Stars 1 Watchers 0 Forks
Languages
TypeScript 99.7%
JavaScript 0.2%
Python 0.1%