Skip to content
JackLucianoPublic

About

A fast, friendly desktop git client in Rust + GPUI: interactive rebase, absorb/split, stacked PRs, 3-way conflict editor, multi-repo workspaces, AI, and undo for everything.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Repository files navigation

Cairn logo

Cairn

A fast, friendly git client for people who outgrew the basics.

Native Rust, GPU-rendered with GPUI. Every risky operation is one click from undone.

CI License: MIT OR Apache-2.0 Platform: Windows Built with Rust Languages

Features · Install · Shortcuts · AI · Build from source · Code signing policy


Cairn's history view with the commit graph

Why Cairn

Most git clients are either a thin layer over the basics or a wall of buttons. Cairn keeps the everyday flow calm, and makes the powerful things safe:

  • Nothing is scary. Cairn saves an undo point before every operation. A bad rebase, reset or amend is one click away from being undone.
  • The advanced stuff is built in. Interactive rebase, absorb, split, stacked pull requests, a three-way conflict editor and bisect work without memorizing a single flag.
  • Many repositories, one place. Group repositories into categories and commit, pull or push several of them together.
  • Fast. A native Rust app drawn on the GPU, no Electron, no web view.

Features

Everyday git, done right

Changes view with line staging Branches, tags and worktrees
Line-by-line staging. Click lines in a diff to stage, unstage or discard exactly what you mean. Switch between unified and split view, jump from change to change, and see on the change map where a file changed. Image diffs come in side-by-side, swipe and onion-skin modes. Branches at a glance. Every branch is a card with its last commit, pull request, how far ahead or behind main it is and whether it would conflict. Filter to the active ones, or to the merged ones you can clean up.
Branch picker Stash shelf
Find any branch in a second. Type a few letters to filter hundreds of branches. Recent ones come first, and each shows its last commit, pull request and what is waiting to pull. Switch, compare, highlight it in History or open a pull request from the same window. Stashes you can recognise. Each stash shows the files inside, the branch it came from and how old it is. Apply, pop or drop it from the card.

Several commits selected in History

Work on many commits at once. Ctrl+click or Shift+click commits in History, then copy all their hashes, cherry-pick them or revert them in one step. Cairn applies them in the order they were made, whatever order you clicked them in.

AI commit messages. "Write message from diff" drafts a summary and description from your staged changes. Tell it how you like your messages in Settings → Commits, or share rules with your team in .cairn/commit-message.md.

History that stays readable. History opens on the branch you are on, so twenty open feature branches don't turn the graph into a wall of lines. Switch to "All branches" when you want the whole picture: every commit is labeled with the branch it was made on, each branch keeps one color from its line to its label, and merged branches get their name back from the merge message. Commits that are not on your branch fade out; click any branch in the legend to highlight it instead. Hover a commit for a quick card, and older commits load as you scroll.

Drag and drop. Drag a branch label onto another branch to merge or rebase it, or drag commits onto a branch to cherry-pick them. Cairn always asks first and tells you if it needs to switch branches.

Find anything, undo anything

  • File history. Every commit that changed a file, followed through renames, with the change each one made.
  • Compare. Pick any two branches, tags or commits and see what is only on each side and how the files differ.
  • Lost & found. Deleted a branch, reset too far or dropped a stash? Cairn lists the commits nothing points at any more and brings them back as a branch in one click.
  • Stashes, properly. Stash only some files, or only the blocks and lines you staged. Look inside a stash before applying it and restore single files from it.
  • Go to file (Ctrl+P). Type part of any file name to open its history, its line history or the file itself.
  • Browse any commit. Look through the files of any commit, branch or tag and save a file as it was then.
  • Search commits. Find commits by message, author, changed file or folder, date, and the code they added or removed, so you can see when something appeared or disappeared.
  • Auto-saved work. Every few minutes Cairn keeps a hidden copy of your uncommitted changes. After a crash or a bad discard, bring them back from Lost & found.
  • A second look before you commit. .env files, private keys, credentials and big files get flagged before they go into a commit, with one-click fixes: leave the file out, add it to .gitignore or store it with Git LFS.
  • Split my mess into commits. A pile of unrelated uncommitted changes? AI sorts the changed blocks into logical commits with messages. Move blocks between them, edit the messages, and Cairn makes the commits in order.
  • History scrubber. Drag along a file's timeline to see it at any version, with the lines that version added highlighted, or press play to watch it grow.
  • While you were away. After a few hours away, History opens with what others put on main, which pull requests merged, and a warning when it touches files you are changing too.
  • Someone else is changing this too. Cairn compares your changes with other people's recent branches and tells you when someone is working on the same files, before it becomes a conflict.
  • Conflicts before they happen. Cairn checks quietly in the background whether your branches and open pull requests would conflict with main, and names the files.
Go to file New branch from an issue
Browse files at a commit Clean up branches
Browse any commit. The files of any commit, branch or tag, ready to read or save. Clean up branches. Merged branches and branches deleted on the server go in one step, with a warning for any that still hold unmerged work.

Add co-authors to a commit

Search commits Auto-saved work in Lost & found
Search commits. By message, author, file, date, or the code a commit added or removed. Auto-saved work. Hidden copies of your uncommitted changes, ready to bring back.

Private and big files flagged before a commit

Split uncommitted work into commits

While you were away Someone else is changing the same file
While you were away. What landed on main, who did it, and which of it touches your files. Overlap warnings. Someone else's branch changes a file you are changing too.

File history timeline scrubber

Pull requests, submodules and large files

Pull request ready to merge

  • Review pull requests in Cairn. A ring shows what each pull request still needs (reviews, checks, conflicts) and what to do next. Read the conversation, commits and checks, tick off files as you review them (Cairn remembers, and unticks a file when it changes again), comment on a line, approve or request changes, check it out locally and merge it. Uses the GitHub CLI.

  • Open pull requests from Cairn. Pick the base branch, reviewers and labels, and let AI write the title and description from your commits. Branches that were never pushed are published for you. Cairn suggests reviewers: the people who last worked on the files you changed.

  • Update branch. When a pull request falls behind its base, bring it up to date with a merge or a rebase in one click.

  • Try a pull request without leaving your branch. One click checks it out into its own folder and opens it in a new tab, your editor or a terminal. Your branch and uncommitted work stay as they are.

  • Review heat map. Files are ranked by how risky they are to review: big changes, files that change often, many authors, no tests changed with them, and sensitive areas such as auth or migrations.

  • Backport. Copy a pull request onto release branches, each with its own branch and pull request. It runs in separate worktrees, so your working tree is never touched.

  • Stacks that restack themselves. When the bottom pull request of a stack merges, Cairn moves the branches above it onto main, pushes them and points their pull requests at main.

  • Issues. Read, filter, comment on, assign, close and reopen issues, open new ones, see the pull requests and branches linked to each, and start a branch for one.

  • GitHub notifications. Review requests, mentions, CI results and merged pull requests show up as Windows notifications. Click one to open it in Cairn.

  • AI review. One click and your AI provider reads the whole pull request and drafts review comments on the exact lines. Untick what you don't want to say and post the rest as one review.

  • Branches from issues. Pick an open issue and get a branch named after it, linked to the issue on GitHub.

  • Auto-merge. Let GitHub merge a pull request by itself once its reviews and checks pass.

  • CI checks. See every GitHub Actions run, read the log of the failed steps, re-run failed jobs, start a workflow by hand, and let AI explain why a run failed.

  • Releases. Cairn suggests the next version, writes the notes from merged pull requests or with AI, and publishes the release.

  • Co-authors. Credit the people you worked with on a commit in two clicks.

  • One commit at a time. Click any commit of a pull request to see only what it changed, and step through them in order.

AI review of a pull request

New pull request

CI checks with failed logs and re-runs Releases
CI checks. Every GitHub Actions run, the log of the failed steps, re-runs, manual workflow runs and an AI explanation of what broke. Releases. The next version is suggested for you, the notes come from merged pull requests or AI, and one click publishes it.

Issues

Suggested reviewers Update a pull request branch
Suggested reviewers. The people who last worked on the files you changed come first. Update branch. A pull request behind its base catches up with a merge or a rebase.
Review heat map and Try it Backport a pull request
Review heat map and Try it. The riskiest files first, and the pull request running in its own folder. Backport. One pull request per release branch, made in separate worktrees.
  • Submodules. See which are missing or on a different commit, download and update them, add new ones and open them as their own tab.
  • Git LFS. Track file types, download LFS files, and lock and unlock files your team edits.

Your tools

Open files and repositories in your editor, send a diff to your external diff tool or a conflict to your merge tool, ignore a file or a whole file type from the Changes list, and save commits as a patch or apply someone else's. Set your programs in Settings → Tools.

Rewrite history without fear

Interactive rebase Absorb and split
Interactive rebase. Reorder, reword, squash, fix up or drop commits. fixup! commits land in the right place automatically, and stacked branches move along. Absorb and split. Staged fixes jump into the commit that last touched those lines. Split a commit that grew too big into several clean ones.

Conflicts and stacks

Three-way conflict editor Stacked branches
Three-way conflict editor. Ours, base and theirs side by side, one-click choices per block and a live preview of the result. Cairn opens it by itself when a pull or rebase stops. Stacked branches and pull requests. Cairn remembers which branch sits on which, so amending a lower branch and restacking just works. Submit the whole stack to GitHub at once.

Many repositories at once

Category workspace

Home shows where you stand. What needs you right now, every pull request waiting for your review across all repositories, and activity charts: a contribution calendar, commits per week and who contributed how much.

Categories work like folders for your repositories. Open one to fetch, pull or switch every repository together, and see every pull request waiting for your review across them in one place. When several repositories are on a branch with the same name, Cairn treats them as one linked change you commit and push in a single step.

Investigate

Line history Visual bisect
Line history. Blame with age coloring, and every earlier version of any line. Visual bisect. Mark commits good or bad, or let a test command decide, and Cairn narrows down the commit that broke things.

Ask AI

Ask AI

Explain a commit, spot what could break, summarize your day, review before you push, write a commit message or a pull request description, or get a suggestion for a tricky conflict.

  • Connect with Claude Code, Codex CLI, an Anthropic API key, or a custom endpoint. In Settings → AI, Automatic detects local CLIs on PATH and prefers Claude Code when both are installed. Select a provider directly to override it. For Codex, sign in with codex login and use Test connection in Cairn.
  • Off until you turn it on. Paths you exclude (such as .env files) are never sent, and anything that looks like a secret is redacted first.
  • API connections can use a monthly spending limit.

Safety net

  • Undo history for every operation, with uncommitted work stashed safely before going back.
  • No surprises. Reset, force push, discard and delete say what will happen, what you would lose and whether you can get it back, before you confirm.
  • Discards you can take back. Cairn keeps a copy before discarding changes or a hard reset; Lost & found → Discarded changes brings them back.
  • Main stays clean. Committing straight to main offers to put the commit on a new branch named after its message.
  • Live progress. Push, pull and fetch show how far along they are in a corner toast, with a button to stop them.
  • Sync your way. Push or sync right after each commit, confirm before syncing, and get a warning when someone rewrote the branch on the server. Switching to a branch brings it up to date first.
  • Checks before commit and push from a .cairn/checks.toml file in your repository.
  • Secret scan that stops API keys, tokens and private keys from leaving your computer.
  • Protected main: Cairn asks before rewriting history on main or master.

Made to fit

Command palette Settings
Command palette for every page, git command, branch and repository. About 90 settings with search and live preview: themes, accent colors, graph style, diff options, identity profiles, signing, AI commit message rules and more.

Theme gallery

Make it yours. Six color themes (Graphite, Midnight, Nord, Solarized, Rosé and High contrast), each in dark and light, four accent colors, a glass window on Windows 11 and a compact toolbar. Drag the panel edges to resize them; Cairn remembers.

Fast by design. Tabs load only when you open them, pages keep what they showed, staging and committing update the screen before git has even finished, huge diffs open with their first part right away, and skeleton placeholders show the shape of the page while it loads. One Sync button fetches, pulls and pushes whatever is needed, and the status bar shows where you stand.

Cairn updates itself the way you choose in Settings → Updates: automatically when you close it, only after you say so, or only when you press "Check now". Downloads show their progress, and Cairn shows what changed after each update:

What's new popup

Install

Download dev.cairn.app-win-Setup.exe from the latest release and run it. It installs for your user only, no admin rights needed. Updates arrive automatically.

Windows releases are signed through SignPath Foundation, which provides free code signing for open source projects (see the code signing policy for how releases are signed and what Cairn sends over the network). Until signing is active, Windows SmartScreen may ask you to confirm the first time ("More info", then "Run anyway").

Requirements

  • Windows 10 or 11. Experimental macOS (Apple Silicon and Intel) and Linux x64 builds are attached to each release as .tar.gz files: plain binaries, not yet signed and without automatic updates. On macOS run xattr -d com.apple.quarantine cairn once after unpacking.
  • Git 2.40 or newer. On Windows, Cairn installs Git for Windows through WinGet if it cannot find Git. On macOS and Linux, install Git separately. Settings → Advanced shows the detected executable and lets you select a different one, detect Git again, or retry installation.
  • Optional: the GitHub CLI for pull requests (run gh auth login once)

Keyboard shortcuts

Action Keys
Command palette Ctrl K or Ctrl Shift P
Go to file Ctrl P
Settings Ctrl ,
History, Changes, Branches Ctrl 1 · 2 · 3
Commit staged changes Ctrl Enter
Fetch · Pull · Push Ctrl Shift F · L · K
Stash Ctrl Shift S
New branch Ctrl Shift B
Ask AI Ctrl Shift A
Undo history Ctrl Z
Refresh F5
Next · previous tab · close tab Ctrl Tab · Ctrl Shift Tab · Ctrl W

Optional Vim keys can be turned on in Settings → Keyboard: j k move, g G jump to the top and bottom, / searches, s stages, f fetches and p pushes.

Checks before commit and push

Put a .cairn/checks.toml file in a repository:

[[check]]
name = "Lint"
run = "cargo clippy -- -D warnings"
on = ["push"]
blocking = true

[[check]]
name = "Unit tests"
run = "npm test"
on = ["commit", "push"]
blocking = false

on lists when the check runs: "commit", "push" or both (the default is push only). A failing blocking check stops the commit or push; a non-blocking one only warns.

Languages

The interface is available in English and Hungarian (Magyar). Switch in Settings → General → Language.

Build from source

You need Rust 1.100 or newer and Git. rust-toolchain.toml makes rustup install the right version for you.

cargo run -p cairn

Release build:

cargo build -p cairn --release

Run the tests and lints the same way CI does:

cargo clippy --workspace --all-targets -- -D warnings
cargo test --workspace

Project layout

Path What it is
crates/core The git engine: history, graph layout, status, diffs, line staging, rebase, absorb, conflicts, stacks, checks, undo, settings. No UI, fully tested.
crates/app The desktop app: windows, pages and dialogs built on GPUI and GPUI Kit.
crates/app/locales English and Hungarian translations.
scripts Version bump and the local Windows release script.

Settings live in %APPDATA%\Cairn\settings.toml, categories and open tabs in %APPDATA%\Cairn\library.json. API keys are stored in Windows Credential Manager, never in files.

Contributing

Issues and pull requests are welcome. Use the bug report, feature request or translation form when you open an issue. Please run clippy and the tests before opening a pull request, and add an entry under [Unreleased] in CHANGELOG.md for anything users will notice. Releases are described in RELEASING.md.

License

Licensed under either of Apache License 2.0 or MIT license, at your option.

About

A fast, friendly desktop git client in Rust + GPUI: interactive rebase, absorb/split, stacked PRs, 3-way conflict editor, multi-repo workspaces, AI, and undo for everything.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages