Back to projects
Open Source · Go CLI / TUI

go-vit

Visual terminal Git manager compiled as a single Go binary

Year
2026
Source
Open Source
Role
Author & maintainer (Golang)
ARCHITECTURE // GO-VITSINGLE GO BINARY
TUI EVENT LOOP[1] Branches[2] Diff & MergeVim keys: j / k / g / GStash + Switch safe flowactionsOS/EXEC RUNNERGit Command Layerstatus · diff · fetch · stashSTDOUT PARSERSHunk & Conflict Parser+ / - lines · Ours / TheirsHOST ENVIRONMENTLocal .git RepoSSH keys · hooks · configCONFLICT HANDOFF$EDITOR Fallbacknvim / vim / code
ZERO CGO · NATIVE GIT COMPATIBILITYGO INSTALL READY

Context & problem

Context-switching between verbose Git commands and heavy GUI clients breaks flow during reviews and merges. go-vit provides a keyboard-driven terminal workflow distributed as a single binary via `go install`.

$go install github.com/FelipeSrutkoske/go-vit@latest
GoTUIGit CLIos/execOpen Source

System architecture

Select any layer to inspect responsibilities, protocol, and stack.

3 layers
TUI Event LoopTTY / KeybindingsGo • Vim Navigation

Tabbed terminal UI (Branches / Changes & Conflicts) driven entirely by keyboard shortcuts.

Technical decisions & trade-offs

Decision 01

Shell out to native `git` via `os/exec` instead of C bindings (`libgit2`)

Why

Avoids CGO build friction, keeps `go install` self-contained across platforms, and automatically respects user SSH keys, hooks, and `.gitconfig`.

Trade-off & mitigation

Requires careful parsing of Git stdout instead of typed C structs; handled by isolating command runners and parsers in a dedicated layer.

Decision 02

Built-in Stash + Switch safety flow on branch checkout

Why

Prevents broken checkouts when switching branches with uncommitted working-tree changes.

Trade-off & mitigation

Adds an explicit stash entry to track; kept transparent by surfacing the action clearly in the UI before executing.

Decision 03

Quick Ours / Theirs conflict resolution with `$EDITOR` fallback

Why

Handles straightforward conflicts in one keypress without reimplementing a full text editor inside the TUI.

Trade-off & mitigation

Complex partial merges hand off to the user's configured editor; an intentional boundary to keep the tool focused and lightweight.

Delivery scope

  • Distributed as a single binary installable via `go install github.com/FelipeSrutkoske/go-vit@latest`
  • Safe local/remote branch switching with automatic Stash + Switch support
  • Line-by-line semantic diff viewer (+ / -) with Vim-style keyboard navigation (j/k/g/G)
  • Visual merge conflict detector offering Ours / Theirs quick actions or direct handoff to `$EDITOR`

Next case study

TrackIt

End-to-end logistics auditability and delivery tracking platform