Coodeen
Guides

Development

Set up the Coodeen dev environment and contribute.

Prerequisites

  • macOS 14 Sonoma or later on Apple Silicon
  • Xcode 26 or later
  • XcodeGen: brew install xcodegen
  • Bun (only needed to fetch a different opencode binary and to run the docs site)
  • Git

Setup

git clone https://github.com/zahinafsar/coodeen.git
cd coodeen

The opencode binary the app bundles lives in apps/desktop/resources/bin/opencode and is committed to the repo, so no download is needed for a normal build.

Running Locally

make -C apps/macos run

This generates apps/macos/Coodeen.xcodeproj from project.yml, builds a Debug app into apps/macos/build/DerivedData, quits any running copy, and opens the new build. To work in Xcode instead, run make -C apps/macos gen and open apps/macos/Coodeen.xcodeproj.

On startup the app spawns opencode serve --hostname=127.0.0.1 --port=0 as a child and connects to it over HTTP.

Building a Release

make -C apps/macos dist

This builds the Release app for arm64, checks that the bundled sidecar runs and the signature is valid, then writes Coodeen-mac-arm64.dmg and Coodeen-mac-arm64.zip to apps/macos/build/dist/.

Publishing

Releases are produced by .github/workflows/build-macos.yml:

  1. Bump MARKETING_VERSION in apps/macos/project.yml.
  2. Merge to main.
  3. CI builds the app on a macos-26 runner. If the tag v<version> doesn't exist yet, it creates the tag and publishes a GitHub release with the DMG and ZIP.

The homepage download button points at releases/latest/download/Coodeen-mac-arm64.dmg, so the new build is live on the site as soon as the release is published. Pull requests that touch apps/macos get a build check without publishing.

Pinning opencode

OPENCODE_VERSION=0.x.y bun run --cwd apps/desktop fetch-opencode

The downloaded version is tracked in apps/desktop/resources/bin/.opencode-version. Commit the new binary so CI bundles it.

Docs Site

bun run dev:docs

Runs Next.js + Fumadocs from apps/docs/.

Project Structure

DirectoryPurpose
apps/macosNative macOS app (SwiftUI)
apps/desktopPrevious Electron app, plus the bundled opencode binary in resources/bin
apps/docsDocumentation site (Next.js + Fumadocs)
scripts/fetch-opencode.js and Electron build helpers

App Layout

Inside apps/macos/Coodeen:

FolderWhat it does
App/App entry, window, menu commands, launch and quit handling
Sidecar/Spawns and supervises opencode, HTTP client, SSE event bus with auto-reconnect, API calls for sessions, prompts, and providers
Stores/Chat store (applies opencode events), workspace state, toasts
Services/Files, git, coodeen.json actions and watcher, preferences, shell environment
Views/SwiftUI views for chat, settings, files, git, terminal, preview, and design canvas