Usage

Usage

Run codemap from the root of the repository you want to pack.

Basic pack

codemap --format markdown --output codemap-output.md

With no output option, codemap writes its default output file.

Choose where output goes

codemap --stdout              # print to stdout
codemap --clipboard           # copy to the clipboard
codemap --output out.xml      # write to a file

--stdout and --clipboard cannot be used together.

Pack a remote repository

codemap --remote https://github.com/owner/repo --remote-branch main

Watch for changes

codemap --watch

Split large output

codemap --split-output 200000

Output is written as numbered files when the rendered content exceeds the given byte size.

Token budget

codemap --token-budget 100000

Files are included until the budget is reached. Token counts use the cl100k_base tokenizer.

Git context

codemap --include-diffs
codemap --include-logs --include-logs-count 20