ccm Claude Code Manager
Claude Code Manager · v0.1.4

Everything
Claude Code remembers, in one quiet place.

ccm is a CLI and TUI for ~/.claude/projects/ — list projects, browse sessions, inspect memory, export to Markdown. No daemon, no config, no cd into folders named like -home-q-my-projects-foo.

View on GitHub
  • Python 3.10+
  • MIT license
  • Three deps
  • Works offline
ccm — ~/.claude/projects/ ✶
✶ ccm · my_projects/ccm q quit
Projects 9
  • my_projects/ccm14 sessions · 3.2 MB
  • work/anthropic-sdk22 sessions · 6.1 MB
  • notes/research-20268 sessions · 1.4 MB
  • my_projects/agent-eval31 sessions · 12 MB
  • scratch/quick-tests3 sessions · 0.4 MB
  • work/claude-rag17 sessions · 4.8 MB
Sessions 14
  • build landing page2m ago · 218 msgs
  • fix textual _size shadow3h ago · 64 msgs
  • ci: actions for tests + pypiyesterday · 110 msgs
  • memory inspector v22d ago · 42 msgs
  • stats: disk usage graph3d ago · 88 msgs
  • export to markdown5d ago · 31 msgs
0
subcommands
0
clean layers
0%
on disk · no daemon
0
config files
The problem

ls ~/.claude/projects/
was never the answer.

Claude Code replaces both / and _ with - when it encodes a project path. So ~/.claude/projects/ fills up with unreadable folders, and du -sh * won't tell you which session ate the disk.

BEFORE $ ls ~/.claude/projects/
drwxr-xr-x  -home-q-my-projects-ccm/
drwxr-xr-x  -home-q-my-projects-agent-eval/
drwxr-xr-x  -home-q-work-anthropic-sdk/
drwxr-xr-x  -home-q-work-claude-rag/
drwxr-xr-x  -home-q-notes-research-2026/
drwxr-xr-x  -home-q-scratch-quick-tests/
# …which one was my_projects vs my-projects?
# which session was 200 MB?
# what's in their memory/ folders?
AFTER $ ccm ls --sort size
PROJECT                          SESSIONS   SIZE   LAST ACTIVE
my_projects/agent-eval                31  12.0M   2 hours ago
work/anthropic-sdk                    22   6.1M   3 hours ago
work/claude-rag                       17   4.8M   yesterday
my_projects/ccm                       14   3.2M   2 min ago
notes/research-2026                    8   1.4M   3 days ago
scratch/quick-tests                    3   0.4M   1 week ago
✓ decoded from real cwd inside each JSONL
What it does

Six things you'd otherwise
script by hand.

✶

Decodes the path encoding correctly

Reads the real cwd from inside each session's JSONL. No naive - → / guessing that confuses my_projects with my-projects.

paths.real_cwd_from_sessions()
✷

A TUI you'll actually want to open

Textual app with two panes, vim keys, a Claude-style asterisk spinner up top, and a delete-confirm modal that won't bite you.

↑↓ · h/l · Enter · m · d · r · q
✸

Export to Markdown, JSON, or raw

Pull any session out into a portable document. Pipe it into a PR description, an issue comment, or a Notion page.

ccm export <p> <s> -f md
✹

Memory file inspector

Surfaces memory/*.md per project — read, dump, or delete individual entries without rummaging through folders.

ccm memory <p> --show NAME
✺

Disk-usage dashboard

Top projects by size, by session count, by recency. Find the 50-MB session you forgot about in three keystrokes.

ccm stats
✻

Scripting-friendly subcommands

Every TUI action has a CLI mirror. Pipe, sort, filter, automate from shell scripts — no headless mode required.

ccm ls -s size -n 10 | head
The TUI

Read it like a newspaper.
Drive it like vim.

Three panes, one cursor, zero modal popups you didn't ask for. Press m for memory, d to delete, Enter to drill in.

ccm ✶
✶ ccm · my_projects/ccm 9 projects · 108 sessions · 32.1 MB
Projects
  • my_projects/ccm14 sess
  • work/anthropic-sdk22 sess
  • notes/research-20268 sess
  • my_projects/agent-eval31 sess
  • work/claude-rag17 sess
  • scratch/quick-tests3 sess
Sessions of my_projects/ccm
  • build landing page2m · 218 msgs · 142 KB
  • fix textual _size shadow3h · 64 msgs · 38 KB
  • ci: actions for tests + pypi1d · 110 msgs · 71 KB
  • memory inspector v22d · 42 msgs · 24 KB
  • stats: disk usage graph3d · 88 msgs · 51 KB
  • export to markdown5d · 31 msgs · 18 KB
Architecture

Three layers. Nothing extra.

Domain logic stays UI-agnostic. The CLI and TUI are two faces of the same core/ — so a subcommand and a key-press do exactly the same thing.

Terminal user cli/ typer subcommands ccm ls · stats · export tui/ textual app screens · widgets core/ projects · sessions · memory stats · export ~/.claude/ projects/

The lossy folder-name encoding is the one bit that requires care. Claude Code replaces both / and _ with -, so real_cwd_from_sessions() reads the actual cwd field from the first session JSONL inside each directory.

CLI reference

Ten commands.
Sane defaults.

ccm ls --sort size -n 10
$ ccm ls --sort size -n 10

PROJECT                          SESSIONS   SIZE   LAST ACTIVE
my_projects/agent-eval                31  12.0M   2 hours ago
work/anthropic-sdk                    22   6.1M   3 hours ago
work/claude-rag                       17   4.8M   yesterday
my_projects/ccm                       14   3.2M   2 min ago
notes/research-2026                    8   1.4M   3 days ago
scratch/quick-tests                    3   0.4M   1 week ago

✓ 6 projects · 95 sessions · 28.0 MB total
Install

One line. No config.
The console command stays ccm.

Python 3.10+ and uv required. Or use pipx / pip --user if you prefer.

Copied to clipboard