Repository navigation
feat: add native Linux desktop client - #20
Merged
Merged
Conversation
- Resolve the platform once as DESKTOP.platform ('macos' | 'linux') and
branch with ts-pattern so each OS-specific path is exhaustive.
- Move single-instance, login item and launch-session setup into
desktop-launch.ts; Linux claims a socket only after no running app answers.
- Linux autostart runs the bundled launcher with DESKTOP_LOGIN=1, the tray
uses the bundled appIcon.png, Tailscale is found on PATH, and zenity
failures surface as errors instead of a cancel.
- Drop the shortcut icon rewrite: Electrobun's installer already writes the
absolute icon path and hashes the entry.
- Quit from the webview goes through Utils.quit so the local server stops
first; Ctrl+Q and the quit bridge are Linux-only, and the app menu is set
only on macOS.
- When the local server exits, the tray shows stopped with Retry, except for
headless and macOS login launches that launchd restarts.
- Updates stay macOS-only; rename dev/build scripts to dev:app and build:app.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎫 Issue
None
🤔 Why
The desktop client was restricted to macOS due to direct Objective-C FFI calls (
/usr/lib/libobjc.A.dylib), macOS-specific tools (dns-sd,osascript,PlistBuddy), and LaunchAgent plists. On Linux, launching a second instance failed to re-activate the background window.📋 What changed
DESKTOP.isDarwin, routing to Electrobun cross-platform notifications on Linux..desktopautostart generation (~/.config/autostart) for Linux.desktop.sock) on Linux so clicking the application icon immediately wakes and focuses the background instance without crashing the JS engine with POSIX signals.linuxbuild options (native WebKitGTK renderer, icon asset) and npm/turbo scripts (dev:linux,build:linux,dev:desktop:linux).Ctrl+Q/Cmd+Qto graceful shutdown.Left out on purpose: Windows-specific packaging and non-x64 Linux packaging (CEF).
💣 Blast radius
Review:
Affected paths:
apps/desktop/electrobun.config.tsapps/desktop/package.jsonapps/desktop/src/desktop.constants.tsapps/desktop/src/desktop.tsapps/desktop/src/desktop-network.tsapps/desktop/src/desktop-notify.tsapps/desktop/src/desktop-objc.tsapps/desktop/src/desktop-settings.tsapps/desktop/src/desktop-update.tsapps/desktop/src/desktop-window.tsapps/desktop/src/types/desktop.types.tsapps/web/src/components/layout/layout-nav-device.tsxapps/web/src/vite-env.d.tspackage.jsonscripts/desktop.tsturbo.json✅ Before review
bun run check,bun run lintandbun run testDESIGN.md, copy in i18norbs-reviewrun in full, findings fixed