{"id":43957421,"url":"https://github.com/kccarlos/gitcontext","last_synced_at":"2026-02-07T05:00:35.329Z","repository":{"id":309330197,"uuid":"1035770898","full_name":"kccarlos/gitcontext","owner":"kccarlos","description":"Build Perfect Context of Your Codebase for Your AI Chatbot","archived":false,"fork":false,"pushed_at":"2026-01-28T06:44:51.000Z","size":772,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-28T22:54:54.708Z","etag":null,"topics":["chatgpt","claude","claude-code","context-engineer","context-engineering","git","llm","prompt","prompt-engineering","software-engineering"],"latest_commit_sha":null,"homepage":"https://gitcontext.xyz/","language":"TypeScript","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/kccarlos.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"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":"2025-08-11T04:20:04.000Z","updated_at":"2026-01-28T06:44:53.000Z","dependencies_parsed_at":"2025-08-11T10:33:55.210Z","dependency_job_id":null,"html_url":"https://github.com/kccarlos/gitcontext","commit_stats":null,"previous_names":["kccarlos/gitcontext"],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/kccarlos/gitcontext","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kccarlos%2Fgitcontext","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kccarlos%2Fgitcontext/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kccarlos%2Fgitcontext/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kccarlos%2Fgitcontext/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kccarlos","download_url":"https://codeload.github.com/kccarlos/gitcontext/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kccarlos%2Fgitcontext/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29186742,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-07T03:35:06.566Z","status":"ssl_error","status_checked_at":"2026-02-07T03:34:57.604Z","response_time":63,"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":["chatgpt","claude","claude-code","context-engineer","context-engineering","git","llm","prompt","prompt-engineering","software-engineering"],"created_at":"2026-02-07T05:00:34.848Z","updated_at":"2026-02-07T05:00:35.318Z","avatar_url":"https://github.com/kccarlos.png","language":"TypeScript","readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"./apps/web/public/gitcontext.svg\" width=\"50\"\u003e\n  \u003cspan\u003eGitContext\u003c/span\u003e\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cem\u003e100% private codebase context engineering tool\u003cbr\u003e\n  Fully local app to package your codebase files and diffs into LLM-friendly format\u003c/em\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/kccarlos/gitcontext/actions/workflows/release.yml\"\u003e\u003cimg src=\"https://github.com/kccarlos/gitcontext/actions/workflows/release.yml/badge.svg\" alt=\"Build Status\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/kccarlos/gitcontext/releases/latest\"\u003e\u003cimg src=\"https://img.shields.io/github/v/release/kccarlos/gitcontext\" alt=\"Latest Release\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/kccarlos/gitcontext/blob/main/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/kccarlos/gitcontext\" alt=\"License\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n---\n\n**GitContext** lets you securely analyze and package local Git repository diffs directly on your machine for quick copy-and-paste into AI Chatbots like ChatGPT, Claude, and others. Available as a high-performance native desktop app (Tauri + Rust) for macOS, Windows, and Linux, or as a web app running entirely in your browser.\n\nSimilar to Repomix or GitIngest, but with key differences:\n\n- **Zero servers, zero uploads** – everything runs entirely locally on your machine or in your browser\n- **Native performance** – desktop app uses Rust for blazing-fast Git operations\n- Supports **Git diffs** between branches, not just files\n- Generate a **file tree** with your selected code/diffs for easy LLM ingestion\n- **One-click prompt templates** tailored for common coding scenarios\n- **Real-time token counting** to stay within LLM context limits\n\n## Downloads \u0026 Installation\n\n### Desktop App (Recommended)\n\nDownload the latest native desktop app for your operating system from the [GitHub Releases](https://github.com/kccarlos/gitcontext/releases/latest) page:\n\n- **macOS**: `.dmg` file\n- **Windows**: `.msi` or `.exe` installer\n- **Linux**: `.AppImage`, `.deb`, or `.rpm` package\n\nThe desktop app offers superior performance with native Rust-powered Git operations.\n\n### Web App\n\nAlternatively, use the web version directly at [gitcontext.xyz](https://gitcontext.xyz) — no installation required!\n\nThe web app runs entirely in your browser using modern Web APIs and never uploads your code anywhere.\n\n---\n\n## What is GitContext?\n\nGitContext is a **privacy-first, local-first** application for analyzing and staging Git repository diffs — all without any cloud services.\n\n**Desktop App** uses:\n- Native file system access with Tauri\n- Blazing-fast Git operations via Rust's `git2` crate\n- Multi-threaded performance for large repositories\n\n**Web App** uses:\n- File System Access API for local-only file system access\n- `isomorphic-git` for client-side Git operations\n- Web workers + IndexedDB caching for performance\n\n**Key features:**\n- Local-only file system access with persistent permissions\n- Real-time Git operations with visual diff analysis\n- Interactive file tree navigation and selective staging\n- Instant token count estimation for LLM context limits (GPT-4, Claude, etc.)\n- Flexible output formats with smart handling of binary files\n- Dark mode support\n\n---\n\n## Why I Built It\n\nAs a developer who frequently works with ChatGPT, Claude, and other LLMs, I found existing tools lacking:\n\n- Needed a **visual way to pick files and diffs** instead of crafting CLI filters\n- Wanted **branch-to-branch diffs** for scenarios like code reviews and bug fixes\n- Preferred an **interactive workflow** over command-line arguments\n- Required **privacy** — no uploading code to third-party servers\n\nPassing only relevant context to an LLM significantly improves accuracy — especially in large codebases with overlapping names and structures. See [Context Rot](https://research.trychroma.com/context-rot) for why trimming irrelevant context matters.\n\n---\n\n## Tech Stack\n\n### Desktop App (Tauri)\n- **Frontend**: React 18 + TypeScript + Vite\n- **Backend**: Rust + Tauri 2.0\n- **Git Operations**: `git2` crate (native Rust)\n- **Token Counting**: `tiktoken` (WASM)\n\n### Web App\n- **Frontend**: React 18 + TypeScript + Vite\n- **Git Operations**: `isomorphic-git` + LightningFS\n- **Token Counting**: `tiktoken` (WASM)\n- **Storage**: IndexedDB for caching\n\n### Shared Packages (Monorepo)\n- `@gitcontext/ui` - Shared React components\n- `@gitcontext/core` - Shared types and utilities\n\n---\n\n## Getting Started\n\nThis project uses a monorepo structure with NPM workspaces.\n\n### Prerequisites\n\n```bash\nnpm install\n```\n\n### Web App\n\nRun the web app in development mode:\n\n```bash\nnpm run web:dev\n```\n\nBuild the web app for production:\n\n```bash\nnpm run web:build\nnpm run web:preview\n```\n\nThe web app will be available at http://localhost:5173\n\n### Desktop App\n\n**Prerequisites**:\n- [Rust](https://rustup.rs/) must be installed\n- Platform-specific dependencies:\n  - **macOS**: Xcode Command Line Tools\n  - **Linux**: `libwebkit2gtk-4.1-dev`, `libappindicator3-dev`, `librsvg2-dev`, `patchelf`\n  - **Windows**: Microsoft Visual C++ Build Tools\n\nRun the desktop app in development mode:\n\n```bash\nnpm run desktop:dev\n```\n\nBuild the desktop app for production:\n\n```bash\nnpm run desktop:build\n```\n\nInstallers will be created in `apps/desktop/src-tauri/target/release/bundle/`\n\n### Testing\n\nRun end-to-end tests:\n\n```bash\nnpm --workspace apps/web run test:e2e\n```\n\nRun unit tests:\n\n```bash\nnpm --workspace apps/web run test:unit\n```\n\n---\n\n## Project Structure\n\n```\ngitcontext/\n├── apps/\n│   ├── web/              # Web application (React + isomorphic-git)\n│   │   ├── src/\n│   │   │   ├── components/\n│   │   │   ├── hooks/\n│   │   │   ├── workers/\n│   │   │   └── utils/\n│   │   └── vite.config.ts\n│   └── desktop/          # Desktop application (Tauri + Rust)\n│       ├── src/          # React frontend\n│       └── src-tauri/    # Rust backend\n│           ├── src/\n│           │   ├── git.rs    # Git operations (git2)\n│           │   └── lib.rs    # Tauri commands\n│           └── Cargo.toml\n├── packages/\n│   ├── ui/               # Shared React components\n│   └── core/             # Shared types and utilities\n└── package.json          # Root workspace config\n```\n\n---\n\n## Development Scripts\n\n| Command | Description |\n|---------|-------------|\n| `npm run web:dev` | Start web app dev server |\n| `npm run web:build` | Build web app for production |\n| `npm run desktop:dev` | Start desktop app in dev mode |\n| `npm run desktop:build` | Build desktop app installers |\n| `npm run lint` | Lint all workspaces |\n| `npm run build` | Build all workspaces |\n\n---\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n---\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n---\n\n## Acknowledgments\n\n- [isomorphic-git](https://isomorphic-git.org/) for browser-based Git operations\n- [git2-rs](https://github.com/rust-lang/git2-rs) for native Rust Git operations\n- [Tauri](https://tauri.app/) for the native desktop framework\n- [tiktoken](https://github.com/openai/tiktoken) for token counting\n\n---\n\n\u003cp align=\"center\"\u003e\n  Made with ❤️ by \u003ca href=\"https://github.com/kccarlos\"\u003ekccarlos\u003c/a\u003e\n\u003c/p\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkccarlos%2Fgitcontext","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkccarlos%2Fgitcontext","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkccarlos%2Fgitcontext/lists"}