| name | calldiff |
| description | Diff call stacks across git commits — like git diff, but for who-calls-whom. Shows which callees appeared, disappeared, or moved under an entrypoint across 23 languages (diff, tree, and reach). Use for agentic code review when call flow changed and line diffs bury the shape of the change. |
| requires_bin | calldiff |
| command | calldiff |
calldiff diff
Diff call stacks between two git trees
Arguments
| Name | Type | Required | Description |
|---|
from | string | no | Before ref (default: HEAD) |
to | string | no | After ref (default: working tree) |
paths | array | no | Limit to these path prefixes |
Options
| Flag | Type | Default | Description |
|---|
--entry | unknown | | Entrypoint symbol(s): functionName or ClassName.method |
--file | unknown | | Entrypoint file(s): indexed source path; expands to that file's exports |
--maxDepth | number | 12 | Max call-tree depth |
--locs | boolean | false | Show call-site source locations (file:line) |
--from | string | | Left / "before" tree |
--to | string | | Right / "after" tree |
Examples
calldiff diff
calldiff diff main
calldiff diff abc123 def456
calldiff diff main feature --entry createAgentSession
calldiff diff main feature --file src/routes.ts
Semantics match git diff: no refs → HEAD vs worktree; one ref → that vs worktree; two refs → compare those trees.
calldiff reach
Find all call paths from an entrypoint to a target symbol
Arguments
| Name | Type | Required | Description |
|---|
ref | string | no | Git ref (default: working tree) |
paths | array | no | Limit to these path prefixes |
Options
| Flag | Type | Default | Description |
|---|
--entry | unknown | | Entrypoint symbol(s): functionName or ClassName.method |
--file | unknown | | Entrypoint file(s): indexed source path; expands to that file's exports |
--to | string | | Target symbol to reach (functionName or ClassName.method) |
--maxDepth | number | 12 | Max call-tree depth |
--locs | boolean | false | Show call-site source locations (file:line) |
Examples
calldiff reach --entry runCheckout --to sendEmail
calldiff reach HEAD examples/checkout --entry runCheckout --to sendEmail
calldiff reach --file packages/api/src/flow.ts --to notify
calldiff tree
View a call tree (no diff) for one or more entrypoints
Arguments
| Name | Type | Required | Description |
|---|
ref | string | no | Git ref (default: working tree) |
paths | array | no | Limit to these path prefixes |
Options
| Flag | Type | Default | Description |
|---|
--entry | unknown | | Entrypoint symbol(s): functionName or ClassName.method |
--file | unknown | | Entrypoint file(s): indexed source path; expands to that file's exports |
--maxDepth | number | 12 | Max call-tree depth |
--locs | boolean | false | Show call-site source locations (file:line) |
Examples
calldiff tree --entry createAgentSession
calldiff tree HEAD --entry PiService.createAgentSession
calldiff tree --file packages/api/src/routes.ts