Skip to main content

A CLI tool to aggregate codebase into a single Markdown file

Project description

Code Collator

Code Collator is a powerful CLI tool designed to streamline your code review and documentation process by collating your entire codebase into a single, organised Markdown file. This is particularly useful for sharing with AI tools like ChatGPT or Claude for analysis, troubleshooting, or documentation.

Use Case

Have you ever needed to provide a comprehensive overview of your codebase for a code review, AI analysis, or detailed documentation? Code Collator simplifies this task by aggregating all your code files into a single Markdown file. This makes it easy to:

  • Share your code with AI tools like ChatGPT or Claude for intelligent analysis.
  • Generate a unified document for code reviews or team collaboration.
  • Create comprehensive documentation for your projects with minimal effort.

Features

  • Full Codebase Collation: Collates all files in the specified directory and subdirectories into one Markdown file.
  • .gitignore Support: Automatically ignores files specified in the .gitignore file if one exists.
  • Customizable Output: Outputs a single Markdown file named collated-code.md by default, with options to specify the path to the codebase directory and output file name.
  • Binary File Inclusion: Includes binary files such as images in the output with a note about their file type.
  • Help Command: Provides a help command to display usage instructions.

Installation

You can easily install Code Collator using pip:

pip install code-collator

Usage

Here’s a basic example of how to use Code Collator:

code-collator --path /path/to/codebase --output my-collated-code.md

For more detailed usage instructions, use the help command:

code-collator --help

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

code_collator-0.1.tar.gz (3.6 kB view details)

Uploaded Source

Built Distribution

code_collator-0.1-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file code_collator-0.1.tar.gz.

File metadata

  • Download URL: code_collator-0.1.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for code_collator-0.1.tar.gz
Algorithm Hash digest
SHA256 d99dacee171c68160fdb8863674398f8edddaff0605b10800917c647005b5671
MD5 fbd5c980d6e4a3179dc3316d9150cfe3
BLAKE2b-256 754d7a3990504eb9deb80f6e50568c4ceba4470aa26c9544c68cb1c18e6cb38a

See more details on using hashes here.

File details

Details for the file code_collator-0.1-py3-none-any.whl.

File metadata

  • Download URL: code_collator-0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for code_collator-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 98cc0556809a780d06638ea9b58324026ee65a837fd3d04dbbef2b288b5296b4
MD5 f3c9cd73f8af55236384eea47e937cce
BLAKE2b-256 7a9ce7e5efa6986b870319eb3be46afb5a864c40100d2618bb7a3ab047879325

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page