Skip to main content

gitcontrol

ci PyPI License: MIT

Gerenciador de Git com três interfaces sobre o mesmo core:

  • TUI em Go/Bubble Tea para operar tudo pelo terminal.
  • CLI JSON (gitcontrol --json) com contrato estável para automação.
  • Desktop em Tauri + React para uma experiência visual.

Interface do gitcontrol

O que funciona

  • Branches: listar, criar, deletar, renomear, checkout (local e remota com tracking), merge e rebase.
  • Commits: log, grafo ASCII, diff completo, cherry-pick e amend.
  • Working tree: status, diff de arquivo, stage/unstage, discard e commit.
  • Remotos: listar, adicionar, remover, fetch, pull e push (com upstream automático no primeiro push).
  • Stash: guardar, listar, aplicar, pop e drop.
  • Tags: listar, criar (leve ou anotada) e deletar.
  • Conflitos: marcar resolvido, abortar e continuar merge/cherry-pick/rebase; edição no editor do sistema/TUI.
  • Reset: soft, mixed e hard.
  • Multi-repo: vários repositórios abertos com troca de ativo.
  • Refresh automático na TUI (fsnotify + timer) e na GUI (polling curto).
  • Instaladores Windows: .msi e .exe (NSIS).

Instalação

PyPI (CLI + TUI)

pip install gitcontrol
gitcontrol --version
gitcontrol

Go

go install github.com/rhyan05/gitcontrol/cmd/gitcontrol@latest

Desktop

Baixe o artefato da sua plataforma na página de releases:

  • Windows: .msi ou instalador NSIS.
  • Linux: .AppImage ou .deb (x86_64).
  • macOS: .dmg (Apple Silicon).

Linux (AppImage):

chmod +x gitcontrol_*.AppImage
./gitcontrol_*.AppImage

Se o AppImage reclamar de FUSE:

sudo apt install libfuse2
# ou rode sem FUSE:
./gitcontrol_*.AppImage --appimage-extract-and-run

Linux (Debian/Ubuntu):

sudo apt install ./gitcontrol_*.deb

macOS: abra o .dmg, arraste o app para Applications e use botão direito → Abrir na primeira execução. Se o Gatekeeper bloquear:

xattr -dr com.apple.quarantine /Applications/gitcontrol.app
open /Applications/gitcontrol.app

Windows: se o SmartScreen avisar, clique em Mais informações → Executar assim mesmo. Os builds não são assinados/notarizados; esse aviso é esperado.

Arquitetura

cmd/gitcontrol/    entrada única: TUI, --json ou --version
internal/git/      core Go (status, log, grafo, remotes, conflitos, ações)
internal/cli/      contrato JSON (envelope ok/data ou ok/error)
packaging/pypi/    wheel universal com os binários Go embutidos
desktop/           app Tauri + React + Tailwind v4
  src/             UI (componentes, features, hooks, sidecar client)
  src-tauri/       runtime Rust, sidecar e ícones

O desktop não reimplementa Git: ele chama o sidecar gitcontrol --json, que é o mesmo binário do core testado em Go.

Requisitos

  • Go 1.27+
  • Node.js 22+ e npm
  • Rust 1.90+ com toolchain MSVC
  • Visual Studio Build Tools com Desktop development with C++
  • WebView2 Runtime (Windows)

TUI / CLI

go test ./...
go run ./cmd/gitcontrol                 # abre a TUI
go run ./cmd/gitcontrol --version
go run ./cmd/gitcontrol --json --repo . status
go run ./cmd/gitcontrol --json log
go run ./cmd/gitcontrol --json graph
go run ./cmd/gitcontrol --json branches
go run ./cmd/gitcontrol --json branch-create <name> [start]
go run ./cmd/gitcontrol --json branch-delete <name> [--force]
go run ./cmd/gitcontrol --json branch-rename <old> <new>
go run ./cmd/gitcontrol --json show <hash>
go run ./cmd/gitcontrol --json diff <path>
go run ./cmd/gitcontrol --json remotes
go run ./cmd/gitcontrol --json remote-add <name> <url>
go run ./cmd/gitcontrol --json remote-remove <name>
go run ./cmd/gitcontrol --json fetch [remote]
go run ./cmd/gitcontrol --json pull [remote] [branch]
go run ./cmd/gitcontrol --json push [remote] [branch]
go run ./cmd/gitcontrol --json checkout <branch>
go run ./cmd/gitcontrol --json merge <branch>
go run ./cmd/gitcontrol --json cherry-pick <hash>
go run ./cmd/gitcontrol --json rebase <upstream>
go run ./cmd/gitcontrol --json resolve <path...>
go run ./cmd/gitcontrol --json abort
go run ./cmd/gitcontrol --json continue
go run ./cmd/gitcontrol --json stage <path...>
go run ./cmd/gitcontrol --json unstage <path...>
go run ./cmd/gitcontrol --json discard <path...>
go run ./cmd/gitcontrol --json commit "mensagem"
go run ./cmd/gitcontrol --json amend ["mensagem"]
go run ./cmd/gitcontrol --json reset <rev> [soft|mixed|hard]
go run ./cmd/gitcontrol --json stash [--untracked] [mensagem]
go run ./cmd/gitcontrol --json stash-list
go run ./cmd/gitcontrol --json stash-pop [index]
go run ./cmd/gitcontrol --json stash-apply [index]
go run ./cmd/gitcontrol --json stash-drop [index]
go run ./cmd/gitcontrol --json tags
go run ./cmd/gitcontrol --json tag-create <name> [mensagem]
go run ./cmd/gitcontrol --json tag-delete <name>

O contrato é sempre um objeto JSON:

{"ok":true,"data":{...}}
{"ok":false,"error":{"code":"git_error","message":"..."}}

Exit code 0 em sucesso e 1 em erro.

Teclas da TUI: tab troca de painel, j/k move, enter faz checkout/diff, d abre o diff do arquivo, s/u faz stage/unstage, c commit, M merge, C cherry-pick, f fetch, p pull, P push, a abortar conflito, x continuar conflito, e editar arquivo em conflito, n nova branch, R renomear, D deletar branch, r rebase, z stash, Z stash pop, t tag, A amend, X discard e [/] para trocar de repositório. A TUI lembra os repositórios e o ativo em ~/.config/gitcontrol/workspace.json (%AppData%\gitcontrol no Windows).

Desktop

cd desktop
npm install
npm run tauri -- dev

O beforeDevCommand compila o sidecar automaticamente (npm run sidecar) e inicia o Vite. Para gerar os instaladores:

cd desktop
npm run tauri -- build

Artefatos:

  • Windows: desktop/src-tauri/target/release/bundle/msi/*.msi e .../bundle/nsis/*.exe
  • Linux: .../bundle/appimage/*.AppImage e .../bundle/deb/*.deb
  • macOS: .../bundle/dmg/*.dmg

Atalhos da GUI: / busca, r atualiza, Ctrl/Cmd+K abre a paleta de comandos, Esc fecha diálogos. O painel de diff é redimensionável pela alça acima dele.

Qualidade

go test ./...
go vet ./...
cd desktop
npm run lint
npm run test
npm run build
cargo check --manifest-path src-tauri/Cargo.toml

Licença

MIT. Veja LICENSE.

Metadata

Release files for gitcontrol 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for gitcontrol 0.1.4
File Interpreter ABI Platform Actions
gitcontrol-0.1.4-py3-none-any.whl Python 3 none any Details for gitcontrol-0.1.4-py3-none-any.whl

Release files / gitcontrol-0.1.4-py3-none-any.whl

Download URL gitcontrol-0.1.4-py3-none-any.whl
Size 8.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
c1da5e6f85aca5e26067c3baead80b398d782f812e7899acf09dadbb46276c99
BLAKE2b-256 checksum
How to use checksums
7d222f06c94bcf53184e77cf15d2628918af4df4b3544eff8babd0ffd061aed4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for gitcontrol 0.1.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page