{"id":49144097,"url":"https://github.com/interestingsoftware/sproutgit","last_synced_at":"2026-05-01T01:00:19.734Z","repository":{"id":352208012,"uuid":"1214285247","full_name":"InterestingSoftware/SproutGit","owner":"InterestingSoftware","description":"A fast, worktree-first Git desktop app built with Tauri, SvelteKit, and Rust. Early prototype.","archived":false,"fork":false,"pushed_at":"2026-04-29T03:50:23.000Z","size":21511,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-29T05:18:12.076Z","etag":null,"topics":["git","git-ui","git-worktree","github","github-actions","github-pages"],"latest_commit_sha":null,"homepage":"http://sproutgit.dev/","language":"Svelte","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/InterestingSoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"docs/security-audit.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-18T11:12:32.000Z","updated_at":"2026-04-29T03:35:01.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/InterestingSoftware/SproutGit","commit_stats":null,"previous_names":["shutter-share/sproutgit","interestingsoftware/sproutgit"],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/InterestingSoftware/SproutGit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/InterestingSoftware%2FSproutGit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/InterestingSoftware%2FSproutGit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/InterestingSoftware%2FSproutGit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/InterestingSoftware%2FSproutGit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/InterestingSoftware","download_url":"https://codeload.github.com/InterestingSoftware/SproutGit/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/InterestingSoftware%2FSproutGit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32481554,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"ssl_error","status_checked_at":"2026-04-30T13:12:06.837Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["git","git-ui","git-worktree","github","github-actions","github-pages"],"created_at":"2026-04-22T02:11:17.954Z","updated_at":"2026-05-01T01:00:19.720Z","avatar_url":"https://github.com/InterestingSoftware.png","language":"Svelte","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"logos/logo.svg\" width=\"80\" alt=\"SproutGit logo\" /\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003eSproutGit\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  A fast, open-source, cross-platform Git desktop app with a \u003cstrong\u003eworktree-first\u003c/strong\u003e workflow.\u003cbr/\u003e\n  Optimized for AI-driven software development.\u003cbr/\u003e\n  Built with \u003ca href=\"https://v2.tauri.app\"\u003eTauri v2\u003c/a\u003e + \u003ca href=\"https://svelte.dev\"\u003eSvelteKit\u003c/a\u003e + \u003ca href=\"https://www.typescriptlang.org\"\u003eTypeScript\u003c/a\u003e + \u003ca href=\"https://www.rust-lang.org\"\u003eRust\u003c/a\u003e.\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#features\"\u003eFeatures\u003c/a\u003e •\n  \u003ca href=\"#workflow-policy\"\u003eWorkflow Policy\u003c/a\u003e •\n  \u003ca href=\"#documentation\"\u003eDocumentation\u003c/a\u003e •\n  \u003ca href=\"#screenshots\"\u003eScreenshots\u003c/a\u003e •\n  \u003ca href=\"#installation\"\u003eInstallation\u003c/a\u003e •\n  \u003ca href=\"#development\"\u003eDevelopment\u003c/a\u003e •\n  \u003ca href=\"#contributing\"\u003eContributing\u003c/a\u003e •\n  \u003ca href=\"#license\"\u003eLicense\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/InterestingSoftware/SproutGit/actions/workflows/ci.yml\"\u003e\n    \u003cimg src=\"https://github.com/InterestingSoftware/SproutGit/actions/workflows/ci.yml/badge.svg\" alt=\"CI Status\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://codecov.io/gh/InterestingSoftware/SproutGit\"\u003e\n    \u003cimg src=\"https://codecov.io/gh/InterestingSoftware/SproutGit/graph/badge.svg\" alt=\"Code Coverage\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/InterestingSoftware/SproutGit/blob/main/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/license-MIT-blue.svg\" alt=\"License: MIT\" /\u003e\n  \u003c/a\u003e\n  \u003cimg src=\"https://img.shields.io/badge/status-early%20prototype-red.svg\" alt=\"Status: Early Prototype\" /\u003e\n  \u003cimg src=\"https://img.shields.io/badge/platform-macOS%20|%20Linux%20|%20Windows-lightgrey.svg\" alt=\"Cross-Platform\" /\u003e\n\u003c/p\u003e\n\n---\n\n\u003e [!NOTE]\n\u003e **This is an AI-driven development project.** Much of the implementation is written by LLMs under our direction.\n\u003e We still plan architecture and execution manually, review outputs carefully, and prioritize security and strong testing standards.\n\u003e We are experienced software engineers and treat AI as a tool, not a substitute for engineering judgment.\n\u003e If you do not want to use or contribute to AI-driven development projects, this repository is probably not for you.\n\n\u003e [!WARNING]\n\u003e **SproutGit is an early prototype.** It is under active development and not ready for regular use. Expect missing features, rough edges, and breaking changes. Contributions and feedback are welcome!\n\n## Why worktree-first?\n\nMost Git GUIs treat branches as the primary unit of work. SproutGit treats **worktrees** as first-class citizens instead.\n\nA Git worktree is a separate working directory linked to the same repository. Unlike branches, which are just pointers, worktrees give you a real, independent directory for each piece of work — no stashing, no context-switching, no losing your place.\n\n**This matters even more with AI agents.** Modern development increasingly involves multiple AI coding agents working in parallel — reviewing code in one context, building a feature in another, fixing a bug in a third. Traditional branch workflows break down here because agents would fight over the same working directory. With worktrees, each agent gets its own isolated directory while sharing the same repo:\n\n```\nmy-project/\n├── root/                    # Main checkout (protected)\n├── worktrees/\n│   ├── feature-auth/        # Agent A is building auth\n│   ├── bugfix-nav/          # Agent B is fixing navigation\n│   └── refactor-api/        # Agent C is refactoring the API\n└── .sproutgit/\n```\n\nNo conflicts, no stash juggling, no waiting. Each agent works independently on its own worktree, and you merge when ready. SproutGit manages this layout so you don't have to think about the underlying `git worktree` commands.\n\n## Features\n\n- **Worktree-first workflow** — Create, switch, and manage Git worktrees in a clean prescribed directory layout\n- **Interactive commit graph** — Lane-based SVG graph with search, selection, and context menus\n- **Diff viewer** — Single-commit and multi-commit range diffs with file list and unified diff display\n- **Branch management** — Checkout, reset (soft/mixed/hard), and create branches from any ref\n- **Publish-aware push** — First push publishes with upstream (`-u`) when none is configured; later pushes use normal tracking\n- **Active worktree sync actions** — Fetch, pull (`--ff-only`), and push/publish from the toolbar for the selected worktree\n- **Remote-first source refs** — Worktree creation prioritizes remote refs (prefers `upstream/*`) to reduce stale local-base mistakes\n- **Workspace hooks** — Run before/after create, remove, and switch operations with dependency ordering and per-hook output\n- **Editor integration** — Open worktrees in your configured editor (respects `GIT_EDITOR`, `core.editor`, `VISUAL`, `EDITOR`)\n- **Dark mode** — Automatic light/dark theme via system preferences\n- **Cross-platform** — macOS, Windows, and Linux via Tauri v2\n- **Lightweight** — Small bundle, native performance, minimal resource usage\n\n## Workflow Policy\n\n- Branch/worktree binding and lifecycle rules: [docs/branch-worktree-policy.md](docs/branch-worktree-policy.md)\n- Workspace hook model and trigger behavior: [docs/worktree-hooks.md](docs/worktree-hooks.md)\n\n## Documentation\n\n- Start at [docs/index.md](docs/index.md) for the maintained documentation entry point\n- Product scope and priorities: [docs/requirements.md](docs/requirements.md)\n- Architecture and backend command patterns: [docs/architecture.md](docs/architecture.md)\n- Security posture and hardening decisions: [docs/security-audit.md](docs/security-audit.md)\n- E2E process and adapter behavior: [docs/e2e-test-process.md](docs/e2e-test-process.md), [docs/tauri-playwright-adapter-cheatsheet.md](docs/tauri-playwright-adapter-cheatsheet.md)\n\n## Workspace Hooks\n\nSproutGit supports workspace-scoped lifecycle hooks stored in `.sproutgit/state.db`.\n\nSupported triggers:\n\n- `before_worktree_create`\n- `after_worktree_create`\n- `before_worktree_remove`\n- `after_worktree_remove`\n- `before_worktree_switch`\n- `after_worktree_switch`\n- `manual`\n\nHook capabilities:\n\n- **Scope classification**: mark hooks as `worktree` or `workspace` scoped depending on whether they primarily manage one worktree or shared workspace resources\n- **Cross-platform shell support**: `zsh` on macOS, `bash` on Linux, `pwsh` on Windows\n- **Dependency graph**: hooks can depend on other hooks by ID\n- **Parallel execution**: hooks run concurrently by default when dependencies are satisfied\n- **Critical vs non-critical behavior**: critical failures can block downstream/operation flow\n- **Timeouts and run logs**: stdout/stderr snippets, status, and error messages are recorded for each run\n- **Live operation tracking UI**: while an operation is locked, the modal shows per-hook pending/running/complete/error status and logs\n- **Manual execution**: enabled hooks can be run on demand from each worktree row via the Run hook action\n\n### Environment variables available to hooks\n\nSproutGit injects runtime context for each hook process:\n\n- `SPROUTGIT_WORKSPACE_PATH`\n- `SPROUTGIT_WORKSPACE_NAME`\n- `SPROUTGIT_ROOT_PATH`\n- `SPROUTGIT_WORKTREES_PATH`\n- `SPROUTGIT_WORKTREE_PATH`\n- `SPROUTGIT_WORKTREE_NAME`\n- `SPROUTGIT_WORKTREE_BRANCH`\n- `SPROUTGIT_WORKTREE_HEAD`\n- `SPROUTGIT_WORKTREE_HEAD_SHORT`\n- `SPROUTGIT_WORKTREE_DETACHED`\n- `SPROUTGIT_TRIGGER`\n- `SPROUTGIT_TRIGGER_PHASE`\n- `SPROUTGIT_TRIGGER_ACTION`\n- `SPROUTGIT_HOOK_ID`\n- `SPROUTGIT_HOOK_NAME`\n- `SPROUTGIT_HOOK_SCOPE`\n- `SPROUTGIT_HOOK_SHELL`\n- `SPROUTGIT_HOOK_CRITICAL`\n- `SPROUTGIT_HOOK_TIMEOUT_SECONDS`\n- `SPROUTGIT_OS`\n\n## Is This Native Git?\n\nNot in this form. Git has native **hook scripts** (for example `pre-commit`, `post-checkout`, `post-merge`) and native **worktree** commands, but it does not provide:\n\n- a workspace-level hook registry in SQLite\n- dependency orchestration\n- critical/non-critical policy controls per hook\n- a GUI for lifecycle hooks tied to managed worktree operations\n- live per-hook progress/status/log rendering in a desktop app\n\nSproutGit builds this orchestration layer on top of native Git primitives so worktree automation is predictable, cross-platform, and visible to users.\n\n## Screenshots\n\n\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"website/src/assets/screenshots/workspace/commit-graph-dark.png\" /\u003e\n    \u003cimg src=\"website/src/assets/screenshots/workspace/commit-graph-light.png\" alt=\"SproutGit workspace — commit graph with worktree markers\" width=\"800\" /\u003e\n  \u003c/picture\u003e\n\u003c/p\u003e\n\n## Installation\n\n### Download\n\nPre-built binaries are published on the [Releases](../../releases) page when a release is cut.\n\n### Build from source\n\n#### Prerequisites\n\n- [Node.js](https://nodejs.org/) 18+ (recommend [nvm](https://github.com/nvm-sh/nvm))\n- [pnpm](https://pnpm.io/) 9+\n- [Rust](https://rustup.rs/) stable toolchain\n- [Git](https://git-scm.com/) 2.20+\n- Platform dependencies for [Tauri v2](https://v2.tauri.app/start/prerequisites/)\n\n#### Steps\n\n```bash\ngit clone https://github.com/InterestingSoftware/SproutGit.git\ncd sproutgit\npnpm install\npnpm tauri build\n```\n\nThe built app will be in `src-tauri/target/release/bundle/`.\n\n## Development\n\n```bash\n# Install dependencies\npnpm install\n\n# Run in development mode (hot-reload)\npnpm tauri dev\n\n# Frontend type checking\npnpm run check\n\n# Frontend production build\npnpm run build\n\n# Rust type checking\ncd src-tauri \u0026\u0026 cargo check\n```\n\n### Shared Cargo build cache for worktrees\n\nSproutGit uses Git worktrees heavily, and Rust's default behavior is to put build artifacts in a `target/` directory inside each checkout. For a Tauri app, that cache can grow to many gigabytes per worktree because it contains dependency artifacts, incremental compilation state, build-script output, and debug symbols.\n\nThis repository supports an optional machine-local Cargo override to move that cache outside individual worktrees:\n\n```toml\n# .cargo/config.toml\ninclude = [{ path = \"local.toml\", optional = true }]\n```\n\nCreate `.cargo/local.toml` on your machine with an OS-appropriate shared cache path:\n\n```toml\n[build]\ntarget-dir = \"/absolute/path/to/shared/cargo-target\"\n```\n\nExamples:\n\n- macOS: `/Users/\u003cyou\u003e/Library/Caches/SproutGit/cargo-target`\n- Linux: `/home/\u003cyou\u003e/.cache/sproutgit/cargo-target`\n- Windows: `C:\\\\Users\\\\\u003cyou\u003e\\\\AppData\\\\Local\\\\SproutGit\\\\cargo-target`\n\nNotes:\n\n- The include mechanism is cross-platform. The path inside `.cargo/local.toml` is intentionally machine-specific and should not be committed.\n- This only changes where future Cargo artifacts are written. It does not delete existing `src-tauri/target` directories that were already created in older worktrees.\n- If disk usage is still high after enabling a shared target dir, remove stale per-worktree build output with `cargo clean` or by deleting old `src-tauri/target` directories.\n\nTo inspect or clean Rust build caches across all Git worktrees for this repository:\n\n```bash\n# Report per-worktree src-tauri/target usage without deleting anything\npnpm run cleanup:rust-targets\n\n# Delete all per-worktree src-tauri/target directories for this repository's worktrees\npnpm run cleanup:rust-targets:delete\n```\n\nThese commands only touch worktree-local `src-tauri/target` directories discovered via `git worktree list`. They do not remove the shared Cargo cache configured in `.cargo/local.toml`.\n\n## Testing \u0026 Coverage\n\n```bash\n# Run backend Rust tests (all targets)\npnpm run test:security\n\n# Run frontend unit tests\npnpm run test:unit\n\n# Run tests with verbose output\ncd src-tauri \u0026\u0026 cargo test --all-targets -- --nocapture\n\n# Generate code coverage report (requires cargo-tarpaulin)\ncargo install cargo-tarpaulin\ncd src-tauri \u0026\u0026 cargo tarpaulin --out Html --output-dir coverage\n\n# View coverage report\nopen coverage/tarpaulin-report.html\n```\n\nAll git and system interactions are security-hardened and tested. See [docs/security-audit.md](docs/security-audit.md) for details.\n\n### E2E test process\n\n- E2E tests live under `e2e/` and run headless by default.\n- `pnpm run test:e2e` runs Playwright directly, with one worker for deterministic desktop flows.\n- Playwright global setup performs a one-time prebuild and launches the built Tauri app binary.\n- `reloadToHome()` is the reset source of truth for in-app navigation/session state between tests.\n\nCommands:\n\n```bash\n# Run E2E suite\npnpm run test:e2e\n\n# Alias for default E2E suite\npnpm run test:e2e:full\n\n# Skip prebuild when iterating locally with an existing built app\nSPROUTGIT_E2E_SKIP_BUILD=1 pnpm run test:e2e\n\n# Canary-only checks\npnpm run test:e2e:canary\n\n# Screenshot capture checks\npnpm run test:e2e:screenshots\n```\n\nPlaywright browser setup:\n\n- `pnpm run setup:playwright` installs Chromium for local E2E runs.\n- `prepare` runs `husky \u0026\u0026 pnpm run setup:playwright` after install.\n- Set `SPROUTGIT_SKIP_PLAYWRIGHT_SETUP=1` to skip automatic browser setup.\n\nPre-commit gate (`.husky/pre-commit`) runs:\n\n1. `pnpm run cleanup:rust-targets:delete`\n2. Rust unit tests\n3. `pnpm run test`\n4. lint\n5. type check\n6. full E2E suite\n\n## Project Structure\n\n```\nsproutgit/\n├── src/                          # SvelteKit frontend\n│   ├── app.css                   # Design tokens (--sg-* CSS vars), animations, themes\n│   ├── lib/\n│   │   ├── sproutgit.ts          # Typed API layer wrapping Tauri invoke() calls\n│   │   ├── toast.svelte.ts       # Toast notification state (Svelte 5 runes)\n│   │   ├── validation.ts         # Branch name / ref validation\n│   │   └── components/           # Reusable UI components\n│   └── routes/\n│       ├── +page.svelte          # Project picker (clone, open, recent)\n│       ├── settings/             # Settings screen\n│       └── workspace/\n│           └── +page.svelte      # Main workspace (worktrees + graph + diff)\n├── src-tauri/\n│   ├── src/lib.rs                # Rust backend: Tauri commands, Git ops, DB\n│   ├── tauri.conf.json           # App configuration\n│   └── Cargo.toml                # Rust dependencies\n├── e2e/                          # Playwright E2E tests and fixtures\n├── docs/                         # Design docs and requirements\n├── logos/                         # App icons (Apple Liquid Glass)\n└── tests/                        # Frontend/unit test files\n```\n\n## Workspace Layout\n\nSproutGit manages repos in a prescribed directory structure:\n\n```\n\u003cworkspace\u003e/\n├── root/                  # Main checkout (protected)\n├── worktrees/             # Managed worktrees\n│   ├── feature-foo/\n│   └── bugfix-bar/\n└── .sproutgit/\n    └── state.db           # Local state (SQLite)\n```\n\nA SproutGit workspace is identified by `.sproutgit/state.db`.\n\n## Tech Stack\n\n| Layer         | Technology                         |\n| ------------- | ---------------------------------- |\n| Desktop shell | Tauri v2 (Rust)                    |\n| Frontend      | SvelteKit + Svelte 5               |\n| Language      | TypeScript + Rust                  |\n| Styling       | Tailwind CSS v4                    |\n| Icons         | Lucide                             |\n| State         | Svelte 5 runes + SQLite (rusqlite) |\n| Git           | CLI via `std::process::Command`    |\n\n## Backend Architecture \u0026 Platform\n\nThe Rust backend uses a **registered action pattern** for all git and system operations, designed for security, auditability, and testability.\n\n**Key design principles:**\n\n- ✅ **Secure-by-default**: Input validation, no shell interpolation, injection-safe\n- ✅ **Auditable**: Every git operation is explicitly registered and testable\n- ✅ **Cross-platform**: macOS, Linux, Windows with environment-aware setup\n- ⚠️ **Composability gap**: Currently single-step operations; multi-step workflows require client orchestration\n\n**For developers building on this platform:**\n\n- Read [docs/architecture.md](docs/architecture.md) for detailed design assessment, reusability analysis, and recommendations for adding transaction/composition support\n- Read [docs/branch-worktree-policy.md](docs/branch-worktree-policy.md) for branch/worktree lifecycle defaults and cleanup safety rules\n- All git/system interactions route through registered helpers in `src-tauri/src/git/helpers.rs`\n- Security-focused unit tests run in CI across all platforms (see `pnpm run test:security`)\n\n## Contributing\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md) for development guidelines, coding conventions, and how to submit changes.\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finterestingsoftware%2Fsproutgit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finterestingsoftware%2Fsproutgit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finterestingsoftware%2Fsproutgit/lists"}