Skip to content

Migrate from Tauri to Electron - #2119

Open
richiemcilroy wants to merge 28 commits into
mainfrom
feature/electron-desktop
Open

Migrate from Tauri to Electron#2119
richiemcilroy wants to merge 28 commits into
mainfrom
feature/electron-desktop

Conversation

@richiemcilroy

@richiemcilroy richiemcilroy commented Aug 12, 2026

Copy link
Copy Markdown
Member

I wanted to see what a migration from Tauri to Electron would look like for Cap. We regularly receive bug reports caused by differences between the browser versions available across OS releases. Electron ships a stable Chromium runtime, giving Cap consistent browser behavior across supported versions.

This keeps the existing Rust backend and UI, replacing the Tauri runtime and bridge with Electron equivalents. Packaging and release workflows have been updated to match.

Electron vs Tauri performance benchmark

Validation: Rust checks, clippy and 141 tests; desktop typecheck and Biome; production renderer and Electron builds; unsigned macOS packaging.

Greptile Summary

The PR replaces the Tauri desktop runtime and packaging pipeline with Electron while retaining the Rust backend and existing renderer.

  • Adds an Electron main process, preload bridge, native-operation adapters, and Rust IPC transport.
  • Reworks desktop builds, signing, updater metadata, and GitHub release staging/promotion.
  • Updates frontend integrations and shared Rust crates for the new runtime.

Confidence Score: 5/5

The PR appears safe to merge with respect to the eligible follow-up findings.

The current workflow stages artifacts under SHA-specific tags, serializes releases by channel and version, validates the complete assembled asset set, re-fetches draft state immediately before promotion, and creates the final tag only after successful builds, so no previously reported blocking release failure remains.

Important Files Changed

Filename Overview
.github/workflows/desktop-release.yml Rebuilds release creation around immutable staging drafts, centralized asset assembly, serialized version releases, and guarded final promotion; the previously reported release races and stranded-tag paths are no longer present.
apps/desktop/electron/main.cjs Introduces Electron application startup, protocol registration, navigation restrictions, backend wiring, and lifecycle management.
apps/desktop/electron/backend.cjs Implements the loopback transport between Electron and the retained Rust backend.
apps/desktop/electron/native.cjs Implements the Electron-side native operations previously supplied through Tauri plugins.
crates/desktop-runtime/src/transport.rs Adds the framed Rust transport and handshake used to communicate with Electron.
apps/desktop/electron-builder.yml Defines Electron packaging, platform targets, bundled resources, and updater artifact generation.

Reviews (16): Last reviewed commit: "fix: validate release policy without adm..." | Re-trigger Greptile

@cursor

cursor Bot commented Aug 12, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@socket-security

socket-security Bot commented Aug 12, 2026

Copy link
Copy Markdown

Warning

Review the following alerts detected in dependencies.

According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.

Action Severity Alert  (click "▶" to expand/collapse)
Warn Critical
Critical CVE: npm shell-quote quote() does not escape newlines in object .op values

CVE: GHSA-w7jw-789q-3m8p shell-quote quote() does not escape newlines in object .op values (CRITICAL)

Affected versions: >= 1.1.0 < 1.8.4

Patched version: 1.8.4

From: pnpm-lock.yamlnpm/concurrently@9.2.1npm/shell-quote@1.8.3

ℹ Read more on: This package | This alert | What is a critical CVE?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Remove or replace dependencies that include known critical CVEs. Consumers can use dependency overrides or npm audit fix --force to remove vulnerable dependencies.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/shell-quote@1.8.3. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn High
Obfuscated code: npm electron-winstaller is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: pnpm-lock.yamlnpm/electron-builder@26.15.3npm/electron-winstaller@5.4.0

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/electron-winstaller@5.4.0. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn High
Obfuscated code: npm tiny-async-pool is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: pnpm-lock.yamlnpm/electron-builder@26.15.3npm/tiny-async-pool@1.3.0

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/tiny-async-pool@1.3.0. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

View full report

Comment thread apps/desktop/src/electron/path.ts Fixed
@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptile-apps please review the PR

Comment thread .github/workflows/desktop-release.yml Outdated
Comment thread apps/desktop/src-backend/src/lib.rs Fixed
@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@superagent-security superagent-security Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Superagent found 1 security concern(s).

Comment thread .github/workflows/desktop-release.yml Outdated
Comment thread .github/workflows/desktop-release.yml Outdated
@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

Comment thread .github/workflows/desktop-release.yml
@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

Comment thread .github/workflows/desktop-release.yml
@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@socket-security

socket-security Bot commented Aug 13, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addednpm/​electron-builder@​26.15.3991006997100
Addednpm/​electron-updater@​6.8.9951007895100
Addednpm/​wait-on@​9.0.110010010090100
Addednpm/​concurrently@​9.2.19910010092100
Addednpm/​electron@​43.4.010010010098100

View full report

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

@richiemcilroy

Copy link
Copy Markdown
Member Author

hey @greptileai, please re-review the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants