
Gitingest
Turns a Git repository or folder into one text file that you can paste into an AI prompt.
- Stars
- 16.1k
- Forks
- 1.2k
- Licence
- MIT
- Language
- Python
- Last update
- 4 days ago
- Type
- Dev tool
What it is
Gitingest takes a Git repository, or a local directory, and produces a single text digest of its contents, including a file tree and summary statistics such as size and token count. The output is formatted so it can be pasted into a large language model prompt. You can also swap 'hub' for 'ingest' in a GitHub URL to get the digest from the website.
- Generate a digest.txt file from a repository and paste it into an LLM chat
- Pull a digest of one subdirectory of a GitHub repo using a tree URL
- Call the ingest function from Python to get summary, tree, and content as variables
- Use the browser extension to digest a GitHub page with one click
Great for
- Developers who want to give an AI assistant context about a codebase
- People who need a quick overview of an unfamiliar repository
- Users who prefer a command line tool or a Python import over a web form
- Teams hosting their own instance with Docker
Not ideal for
- Anyone who needs to work with private repositories without creating a GitHub Personal Access Token, since private access requires one
- Users on Python versions older than 3.8, which the README lists as the minimum
- Projects that need the digest to exclude or include specific files in ways beyond the options the README describes, because those options are only partly covered
How to get it
- 1
Install with a package manager
You'll need: Python 3.8+ · pipx (optional, recommended for the CLI)
Install with pip
pip install gitingestInstall with pipx
pipx install gitingest - 2
Run it
- Install gitingest with pip or pipx.
- Run gitingest https://github.com/coderamp-labs/gitingest to create digest.txt in the current folder.
- Open digest.txt and paste its contents into your AI tool.
- Run gitingest --help to see more options.
- 3
Get the most out of it
- Use --token or the GITHUB_TOKEN environment variable to access private repositories.
- Use --output - to pipe the digest to other command line tools.
- Use --include-submodules if the repository uses submodules.
- Use --include-gitignored if you need files that .gitignore normally skips.
- Use a /tree/ URL to digest only one subdirectory.
Downloads
Strengths
- Simple to start: one pip install and one command
- Offers CLI, Python package, browser extensions, and a self-hosted web app
- Respects .gitignore by default
Trade-offs
- The README does not explain how output is sized or chunked for very large repositories
- Private repositories need a token with its own setup steps
- Self-hosting details beyond Docker and environment variables are not covered in the truncated README
How it compares
| Project | Stars | Type | Level | Updated | Best for |
|---|---|---|---|---|---|
| gitingest (this) | 16.1k | Dev tool | beginner | 4 days ago | Developers who want to give an AI assistant context about a codebase |
| repomix | 29.1k | CLI | beginner | 5 days ago | Developers who want to ask an AI assistant questions about a whole project |
| black | 42.1k | Dev tool | beginner | 4 days ago | Python developers who want formatting handled automatically |
| gitdiagram | 18.7k | App | intermediate | 7 days ago | Developers getting oriented in an unfamiliar codebase |
| opencode | 13.8k | CLI | beginner | 1.1 years ago | Developers who want an AI coding helper inside a terminal rather than a browser or IDE |
| CodeEdit | 23.1k | App | beginner | 20 days ago | Developers on a Mac who work on non-Apple projects and want a native macOS editor |
Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.