Skip to content

Sessions and projects

A session stores conversation messages, completed tool results and metadata. Writes occur after each completed message or tool operation. An interrupted stream or an in-flight external operation may be incomplete.

Resuming

gdc print --session-id <id> --resume "add tests for the change"

--resume reloads saved context. Without it, the same id appends history while the in-memory conversation starts fresh. Resume does not replay previous tools; a newly requested operation may still act on the same files.

In the terminal, open an existing session through /sessions or Alt+S.

Inspecting

gdc sessions list
gdc sessions show <id>
gdc sessions show <id> --json

Projects

Project-scoped CLI queries walk upward to a .git marker, falling back to the current directory. A project's .gdc/ holds configuration, profiles, skills and memory.

Mode Default session database
gdc print, gdc serve, data commands ~/.gdc/sessions.db or [storage].path
Local gdc-tui ~/.gdc/projects/<slug>/sessions.db
Remote gdc-tui --bind Server's database

To inspect local TUI history, use gdc sessions list --all-projects or point --db-path at its database for commands on individual sessions. --all widens scope within the selected database; it does not scan other databases.

Working across projects

gdc sessions list --all
gdc sessions list --cwd /path/to/repo
gdc sessions list --all-projects

Subagent sessions

Workers have child sessions linked to their parent. Forks also create child sessions. Inspect the relationships:

gdc sessions list --tree
gdc sessions list --root-only

Housekeeping

gdc storage gc 30 --dry-run
gdc storage gc 30

Deletion asks for confirmation. See Sessions and data.