repomix
Package entire code repositories into single AI-friendly files using Repomix. Capabilities include pack codebases with customizable include/exclude patterns, generate multiple output formats (XML, Markdown, plain text), preserve file structure and context, optimize for AI consumption with token counting, filter by file types and directories, add custom headers and summaries. Use when packaging codebases for AI analysis, creating repository snapshots for LLM context, analyzing third-party librari
Security Assessment
Detected risks:
About repomix
Repomix is a tool designed to efficiently package entire code repositories into AI-friendly files. It streamlines the process of preparing codebases for analysis by AI models, such as large language models (LLMs) like Claude, ChatGPT, and Gemini. By transforming code repositories into a single, easily digestible file, Repomix helps automate the analysis of large codebases, making it easier for AI to understand and process the contents. This eliminates the need for manual code parsing and restructuring, providing a more efficient way of handling complex software projects.
Repomix offers a wide range of features designed to customize the packaging process. Users can filter files using custom inclusion and exclusion patterns, specify the output format (XML, Markdown, plain text, or JSON), and even strip comments from code to reduce noise. Additionally, it supports remote repository processing, token counting for LLM context management, and ensuring security by checking for sensitive data. With its git-aware processing, Repomix respects `.gitignore` rules and can handle code repositories hosted on platforms like GitHub without the need for cloning. It also provides options for adding custom headers, summaries, and organizing the content for easier AI consumption.
Repomix is ideal for a variety of use cases, including code review preparation, security audits, documentation generation, bug investigation, and implementation planning. It is particularly useful for teams and developers working with large codebases or third-party libraries. By transforming code into an easily interpretable format for AI models, Repomix helps speed up tasks such as generating code documentation, reviewing changes, and analyzing security vulnerabilities. This makes it a valuable tool for developers, security auditors, and AI-driven analysis tasks.
FAQ
How do I install Repomix?
Repomix can be installed using npm or Homebrew. For npm, use the command 'npm install -g repomix'. For Homebrew (on macOS or Linux), use 'brew install repomix'.
Can Repomix process remote repositories?
Yes, Repomix can process remote repositories without cloning. Use 'npx repomix --remote owner/repo' to process a repository directly from GitHub or other supported platforms.
What file formats does Repomix support for output?
Repomix supports XML, Markdown, JSON, and plain text formats for output. You can specify the desired format with the '--style' flag.
Can Repomix remove comments from code?
Yes, Repomix can strip comments from various programming languages, including JavaScript, TypeScript, Python, and more. Use the '--remove-comments' flag to enable this feature.
Does Repomix support token management for LLMs?
Yes, Repomix counts tokens for each file, total repository, and per-format output. This helps manage LLM context limits, such as those for Claude, GPT-4, and GPT-3.5.
Install repomix
Quick Setup:
- Copy the skill folder to
.claude/skills/ - Claude will automatically detect and use the skill
Repository
mrgoonie/claudekit-skills