SurfSense/surfsense_desktop
DESKTOP-RTLN3BA\$punk c3f242a6b2 feat: fix desktop auth issues
- Added logging for JSON parsing failures in structured output to aid in debugging.
- Updated the TranscriptTurn model to ignore unknown keys, improving flexibility for future model variations.
2026-06-25 20:58:50 -07:00
..
assets fix(desktop): ship multi-size icons so linux launchers can find them 2026-05-22 20:04:21 +02:00
build feat(desktop): enable hardened runtime and entitlements for mac signing 2026-04-30 15:39:30 -07:00
scripts feat: fix desktop auth issues 2026-06-25 20:58:50 -07:00
src refactor(ipc): remove showDashboardAfterAuth function and its invocation after OAuth token retrieval 2026-06-25 04:37:03 +05:30
.env.example feat(oauth): implement OAuth page rendering and enhance authentication flow 2026-06-24 18:37:04 +05:30
.gitignore chore: add .env to desktop gitignore 2026-04-11 10:45:01 +02:00
.npmrc feat: add native module support for desktop autocomplete 2026-04-02 13:18:20 +02:00
electron-builder.yml fix(desktop): ship multi-size icons so linux launchers can find them 2026-05-22 20:04:21 +02:00
package.json chore(dependencies): update electron to version 42.4.0 and adjust related package versions in pnpm-lock.yaml 2026-06-20 04:27:35 +05:30
pnpm-lock.yaml chore(dependencies): update electron to version 42.4.0 and adjust related package versions in pnpm-lock.yaml 2026-06-20 04:27:35 +05:30
pnpm-workspace.yaml chore: update pnpm workspace configuration to include root package 2026-03-18 13:20:37 -07:00
README.md Extend desktop package scripts and local dependency compose 2026-04-24 19:15:02 +02:00
tsconfig.json feat(desktop): add tsconfig for Electron TypeScript files 2026-03-17 16:18:44 +02:00

SurfSense Desktop

Electron wrapper around the SurfSense web app. Packages the Next.js standalone build into a native desktop application with OAuth support, deep linking, and system browser integration.

Prerequisites

  • Node.js 18+
  • pnpm 10+
  • The surfsense_web project dependencies installed (pnpm install in surfsense_web/)

Development

pnpm install
pnpm dev

This starts the Next.js dev server and Electron concurrently. Hot reload works — edit the web app and changes appear immediately.

On Linux, pnpm dev runs Electron through scripts/electron-dev.mjs: it sets ELECTRON_DISABLE_SANDBOX=1 for the sandbox issue and passes --ozone-platform=x11 (XWayland) unless SURFSENSE_ELECTRON_WAYLAND=1 is set, so dev tends to behave closer to X11 for shortcuts and Ozone. Packaged Linux builds are unchanged.

Configuration

Two .env files control the build:

surfsense_web/.env — Next.js environment variables baked into the frontend at build time:

surfsense_desktop/.env — Electron-specific configuration:

Set these before building.

Build & Package

Step 1 — Build the Next.js standalone output:

cd ../surfsense_web
pnpm build

Step 2 — Compile Electron and prepare the standalone output:

cd ../surfsense_desktop
pnpm build

Step 3 — Package into a distributable (after steps 12):

pnpm dist:mac      # macOS (.dmg + .zip)
pnpm dist:win      # Windows (.exe)
pnpm dist:linux    # Linux (.deb + .AppImage)
pnpm pack:dir      # optional: unpacked app only → release/… (run that binary yourself)

Step 4 — Find the output:

ls release/