DEV Community

Cover image for I Built a Blazing-Fast, No-Fear Git Client in Rust & Svelte 5 That Uses <85MB RAM (Goodbye 1GB Electron Bloat)
Hoàng Long
Hoàng Long

Posted on

I Built a Blazing-Fast, No-Fear Git Client in Rust & Svelte 5 That Uses <85MB RAM (Goodbye 1GB Electron Bloat)

⚡ FlowGit: The Blazing-Fast, No-Fear Git Client Built for Developers Who Value Their RAM and Sanity

Every software engineer uses Git daily. And almost everyone has faced that cold-sweat moment:

  • You accidentally hit "Discard All Changes" on 300 lines of uncommitted code, and it's gone forever.
  • You botched an interactive rebase or ran git reset --hard onto the wrong upstream branch, scrambling your commits.
  • You launched your favorite Git GUI, only to watch it spin up 6 background Chromium processes, devour 1.2 GB of RAM, and turn your laptop fan into a jet engine.
  • You opened a monorepo with 40,000 commits, and scrolling the DAG graph felt like 10 FPS dial-up.

I decided enough was enough. Over the past months, I built FlowGit — a next-generation visual Git client engineered from the ground up with Tauri v2, a native Rust (libgit2) core, and Svelte 5 Runes.

Here is why it's different, how it solves the biggest flaws in today's Git client landscape, and what went into building it.


FlowGit in Action

⚡ FlowGit running a 60 FPS hardware-accelerated commit graph, Monaco Split Diff, and 1-click command palette.


🥊 The Current Git Client Landscape: Why We Need Something Better

Let's be honest about the tools currently on the market:

Client Strengths The Hidden Pain Points
GitKraken Beautiful UI, great features Electron bloat (800MB–1.5GB RAM), expensive recurring subscription ($60–$180/yr), requires login, locks private repos
GitHub Desktop Free, simple to use Built on Electron, lacks advanced power features (interactive rebase, 4-pane conflict resolver, worktrees, sparse checkout)
SourceTree Classic feature set Legacy codebase, slow cold launch (5–8s), prone to freezing on large diffs, clunky UI
Sublime Merge / Fork Native, fast Closed source, paid licenses ($99+ / $49), no integrated GitHub PR review/Actions CI runner, basic diff viewers

None of them addressed the #1 fear every developer has: Accidental Data Loss.


🛡️ Problem #1: Accidental Discard Means Permanent Code Loss (Solved!)

The Nightmare:

You've spent the entire afternoon sketching out a tricky algorithm. Before committing, you stage the files you want, and click "Discard Unstaged Changes" to clean up temporary debug lines.
Suddenly you realize: your best changes were in the unstaged hunks.

In every single existing Git client, Git deletes those uncommitted lines from your disk. They are not in git reflog, not in .git/objects, and not in the OS recycle bin. They are erased forever.

The FlowGit Solution: 48-Hour Safe Discard Trash

Before FlowGit touches a single byte on your disk:

  1. It automatically computes a delta snapshot of the exact discarded hunks or files.
  2. It writes them into an embedded local SQLite snapshot database.
  3. If you made a mistake, open the Trash Inspector (48h), review the diff, and click Restore. Your uncommitted code is instantly resurrected.

48-Hour Safe Discard Trash

No fear. No panic. You can discard freely knowing you have a 48-hour safety net.


⏳ Problem #2: Botched Rebases & Resets (Universal Ctrl + Z Time Machine)

The Nightmare:

You run an interactive rebase or a reset, pick the wrong target, and end up with a detached HEAD or scrambled commits. You have to open the terminal, run git reflog, read dozens of cryptic SHA lines, and hope you don't break things further.

The FlowGit Solution: Reflog Time Machine (Ctrl + Z)

FlowGit maintains an internal transactional Action Journal. If any operation — checkout, reset, rebase, branch switch, or stash — turns out to be a mistake, you literally just hit:

Ctrl + Z (or Cmd + Z on macOS)

FlowGit computes the reverse transition, resolves the previous reflog pointer, and safely restores your workspace state in milliseconds.

Reflog Time Machine


⚡ Problem #3: The 1GB Electron RAM Tax (< 85MB Native Rust Engine)

The Nightmare:

Why does a tool whose primary job is parsing text trees and graphs require 1.2 GB of RAM and 8 helper processes? Because bundling Chromium and Node.js for every desktop utility is taxing our machines.

The FlowGit Solution:

  • Backend: 100% Native Rust 2024 leveraging direct C-bindings to libgit2. No spawned CLI sub-processes overhead, no intermediate shell parsing.
  • Frontend: Svelte 5 compiled to lean, zero-overhead vanilla JavaScript using Runes ($state.raw eliminates proxy overhead on 50,000+ commit arrays).
  • Runtime: Tauri v2 utilizing the native OS Webview (WebView2 on Windows, WebKit on macOS).

📊 Benchmark Comparison (Repo with ~35,000 commits):

Metric ⚡ FlowGit (Tauri v2 + Rust) 🌐 GitKraken / Electron 🏛️ SourceTree
Idle RAM Usage < 85 MB 750 MB – 1.4 GB ~380 MB
Cold Startup Time < 0.4s 4.2s – 7.0s 5.5s – 9.0s
Installer Size ~30 MB ~180 MB ~120 MB
Graph FPS (50k Commits) Locked 60 FPS 20 – 40 FPS (stutters) Frame drops

🚀 Problem #4: Stuttering Graphs on Massive Repositories (OffscreenCanvas Web Worker)

Most Git GUIs render their Directed Acyclic Graph (DAG) using SVG or HTML DOM elements. When you have a repository with 50,000+ commits across hundreds of branches, the browser's layout engine collapses under DOM tree recalculations.

FlowGit isolates the graph entirely:

  1. Rust rayon computes the commit lane topology and Bézier spline routes in parallel across CPU cores.
  2. The UI delegates 100% of the canvas painting to an OffscreenCanvas inside a dedicated Web Worker (graphWorker.ts).
  3. The main UI thread never drops a single frame. Virtual scrolling keeps memory flat regardless of whether you're browsing 500 commits or 150,000 commits.

⚔️ Problem #5: Confusing Merge Conflicts (4-Pane 3-Way Monaco Resolver)

Merge conflicts with raw conflict markers (<<<<<<< HEAD, =======, >>>>>>>) are prone to manual editing mistakes.

FlowGit integrates a 4-Pane 3-Way Conflict Resolver powered by Monaco Editor (the exact code editor powering VS Code):

  • Ours (Current Branch)
  • Base (Common Ancestor)
  • Theirs (Incoming Branch)
  • Interactive Result Preview

You can adopt entire files, click individual change blocks, or edit directly in the syntax-highlighted editor with full linting support.

4-Pane Conflict Resolver


🔍 Surgical Code Review & Monaco Diff Editor

A Git client is only as good as its diff viewer. FlowGit gives you a first-class code viewing experience:

  • Split & Unified Views: Powered by Monaco Editor with full language syntax highlighting and minimap.
  • Line-by-Line & Hunk Staging: Press Space to stage selected lines or whole hunks.
  • Interactive Blame & File History: Click any line to see who wrote it, when, and jump straight to that commit in the graph.

Monaco Split Diff


🧰 Power Tools You Usually Have to Use Terminal For

FlowGit isn't just for basic commits. It bundles power features that normally require complex CLI gymnastics:

  1. Git Worktrees Studio: Work on multiple branches simultaneously in isolated physical folders. No need to stash or switch branches when an urgent hotfix comes in.
  2. Interactive Rebase & Stacked Commits: Drag-and-drop commits to reorder, squash (S), drop, or edit messages visually with dry-run safety.
  3. Ghost Preview: When dragging a branch onto another, FlowGit simulates the merge/rebase in-memory and shows you whether it will conflict before you release the mouse button!
  4. History Nuker: Accidentally committed a .env file or an AWS secret key? History Nuker scrubs the file across 100% of your repository history in seconds.
  5. Universal Command Palette (Ctrl + K): Jump to any branch, trigger Git actions, or switch repositories at the speed of thought.

Universal Command Palette


🌐 Deep GitHub Integration: PRs & Realtime Actions CI/CD

Leave your browser tabs closed:

  • GitHub Pull Requests: Browse PRs, inspect file diffs, leave inline review comments, and merge directly inside FlowGit.
  • GitHub Actions Runner: View CI/CD workflow runs in real-time, inspect step status trees, stream ANSI terminal logs, and re-run failed jobs.

💻 Tech Stack Under The Hood

For those curious about the engineering:

  • Core Engine: Rust (2024 edition) + git2-rs (libgit2 C bindings) + rayon multi-threading + tokio async IO.
  • Desktop Framework: Tauri v2 (IPC Capability permission model, zero-copy serialization).
  • Frontend: Svelte 5 (Runes architecture: $state, $derived, $effect, $state.raw).
  • Styling: Tailwind CSS v4.
  • Editors: Monaco Editor & Monaco Diff Editor.
  • Local Storage & Safety: rusqlite (SQLite database for 48h Safe Discard & Action History Journal).
  • Security: Signed updates with Ed25519 keys via GitHub Releases; OAuth tokens stored in Windows Credential Manager / macOS Keychain.
  • Internationalization: 100% native bilingual support (English & Tiếng Việt).

🚀 Try FlowGit Today (Free & Open Source)

FlowGit is free, 100% open-source under the MIT License, and respects your privacy (zero telemetry, zero tracking, works completely offline).

# Clone and run locally in under 2 minutes:
git clone https://github.com/longgoll/flow-git.git
cd flow-git
npm install
npm run tauri dev
Enter fullscreen mode Exit fullscreen mode

💬 I'd love your feedback!

What is the biggest frustration you currently have with your Git workflow or current Git client? Let me know in the comments below!

If you like what we're building, please consider dropping a ⭐ Star on GitHub — it helps the project reach more developers! ⚡

Top comments (0)