Interactive TUI for selecting and packing repository files into an AI-friendly prompt.
RepoPacker provides a terminal-based user interface to navigate your project, select specific files
and directories, and then generate a consolidated text block. This block includes the content of the
selected files, formatted for easy input into large language models (LLMs) or for archival purposes.
It respects .gitignore rules and offers additional filtering capabilities.
- Interactive file tree navigation.
- Selection of multiple files and directories.
- Respects
.gitignorefiles and custom ignore patterns. - Filters out binary files and overly large files.
- Copies the packed output to the system clipboard.
- Recent project history.
- Customizable output format (currently XML-like).
- Keyboard-driven interface.

You can install repopacker using pipx (recommended for CLI tools) or pip:
Using pipx:
pipx install repopackerUsing pip:
pip install repopackerTo start RepoLlama, simply run the command:
repopackerThis will open the TUI in the current directory.
You can also specify a path to a project:
repopacker /path/to/your/projectNavigate the tree, select files/folders, and press 'c' to copy the packed content to your clipboard.
RepoPacker is designed to be primarily keyboard-driven for efficiency.
| Key | Action | Description |
|---|---|---|
Ctrl+Q |
Quit | Exit the application. |
F5 |
Open Folder | Open the folder selection dialog. |
c |
Copy Prompt | Generate and copy the packed file content. |
a |
Select All (Project) | Mark all files/folders in the project for packing. |
d |
Deselect All (Project) | Clear all selections in the project. |
Ctrl+A |
Select Content (Dir) | Mark all items within the currently focused folder. |
Ctrl+D |
Deselect Content (Dir) | Clear selections within the focused folder. |
Ctrl+\ |
Command Palette | (Future feature) Open command palette. |
F1 |
Toggle Dark/Light | Switch between dark and light mode. |
? |
Help | (Future feature) Show help screen. |
| Key | Action | Description |
|---|---|---|
Up / k |
Cursor Up | Move the cursor up in the tree. |
Down / j |
Cursor Down | Move the cursor down in the tree. |
Enter |
Toggle Expand/Select | Expand/collapse a directory or select/deselect a file. |
Space |
Toggle Select (Item) | Select/deselect the item under the cursor. |
The sidebar on the right will show a list of files that will be included in the packed output based on your current selections.
Contributions are welcome! Please see CONTRIBUTING.md for guidelines on how to contribute, including setting up your development environment, our branching model, and coding standards.
- Add support for more fine-grained include/exclude patterns (beyond
.gitignore). - Implement configuration file for default ignores, max file size, etc.
(
~/.config/repopacker/config.toml). - Add options for different output formats (e.g., plain text, JSON).
- Implement a "Copy as Markdown" feature.
- Enhance TUI with more visual cues and better mouse support (where appropriate).
- Develop a comprehensive test suite.
- Add a command palette for quick actions.
- Create a proper help screen within the application.
- Package for conda-forge.
- Improve error handling and reporting in the TUI.
This project is licensed under the MIT License - see the LICENSE file for details.
Copyright (c) 2024 Manuel Arce.
If you use RepoPacker in your work or research, please consider citing it (details TBD once a stable release/DOI is available).