Repomix

Active
GitHub TypeScript MIT

Description

Repomix packs your entire repository into a single AI-friendly file, perfect for feeding your codebase to LLMs like Claude, ChatGPT, and DeepSeek for analysis, review, or code generation.

Key Features

  • One-Command Packing — Pack entire repo into a single AI-friendly file (XML/Markdown/Plain Text) with one command
  • Token Counting — Provides per-file and total repository token counts for LLM context limit management
  • Security Scanning — Integrates Secretlint to automatically detect and prevent sensitive data leakage
  • Code Compression — Uses Tree-sitter to extract key code elements, reducing tokens while preserving structure
  • Git-Aware — Automatically respects .gitignore, .ignore, and .repomixignore rules
  • Multiple Output Formats — Supports XML, Markdown, and Plain Text as AI-optimized output formats

Use Cases

💡 Packing codebases to send to Claude/ChatGPT for code review and refactoring
💡 Providing full project context to LLMs for cross-file code generation
💡 Generating AI-friendly files with one click via browser extension on GitHub repo pages
💡 Analyzing large codebases within limited token windows using compression mode
💡 Integrating as an MCP tool into AI-powered development workflows

Quick Start

npx repomix@latest

# Or install globally
npm install -g repomix
repomix

# After generating repomix-output.xml, send to AI:
# "This file contains all files in the repo. Please review for refactoring."

Related Projects