Skip to content
About80Ninjas edited this page Aug 25, 2025 · 1 revision

Frequently Asked Questions (FAQ)

Welcome to the concat FAQ! This page answers common questions about the tool.


General

What is concat?

concat is a command-line utility that scans a project directory and combines all its files into a single, comprehensive Markdown file. The output starts with a directory tree structure, followed by the complete contents of each file.

Why would I use this tool?

The primary use case for concat is to package the entire context of a software project into a single text block. This format is perfect for pasting into Large Language Models (LLMs) like ChatGPT, Claude, or Gemini. It allows the AI to get a complete understanding of your codebase at once, which is far more efficient than uploading files one by one. 🤖


Installation & Troubleshooting

I ran the curl command, but the terminal says concat: command not found. What's wrong?

This is a common issue that usually points to one of two things:

  1. The file is not in your system's PATH. The PATH is a list of directories your terminal searches for executable programs. For the concat command to work from anywhere, the file must be in one of those directories.

    • On Linux and macOS, a common location is /usr/local/bin. Make sure you completed the sudo mv concat /usr/local/bin/ step.
    • On Windows, ensure the folder where you placed concat.exe is listed in your Path Environment Variable.
  2. The file is not executable. On Linux and macOS, files downloaded with curl don't always have permission to run. You need to grant it permission.

    • Run this command: chmod +x concat

Does concat work on Windows?

Yes. The release process automatically builds a binary for Windows (concat-windows-amd64.exe and concat-windows-arm64.exe). You can download it from the [Releases page](https://github.com/about80ninjas/concat/releases/latest) and use it in PowerShell or Command Prompt.


Usage

How do I ignore a large directory like node_modules or vendor?

Use the --exclude flag. This flag accepts glob patterns, which are like wildcards for file paths. To exclude a single directory and all its contents, use /* at the end of the directory name.

# Exclude a single directory
concat --exclude "node_modules/*" .

# Exclude multiple directories and file types
concat --exclude "node_modules/*,vendor/*,*.log" .

How can I process only certain types of files, like .py and .md?

Use the --include flag with a comma-separated list of glob patterns. When this flag is used, concat will ignore any file that does not match one of the patterns.

concat --include "*.py,*.md" .

What happens to images, executables, and other binary files?

By default, concat detects binary files and skips them. It will print a [skipped binary file] message in their place to keep the output clean and readable.

If you absolutely need to include the data from a binary file, you can use the --include-binaries flag. This will write a hexadecimal dump of the file's contents into the output.

Can I change the default output filename?

Yes. Use the -o (or --output) flag to specify your desired filename.

concat -o my-project-snapshot.md .

Contributing

How can I contribute to the project?

Contributions are highly encouraged! If you've found a bug or have an idea for a new feature, please open an issue on GitHub. If you'd like to contribute code, you can fork the repository and submit a pull request. The README.md contains instructions for building the project from source.