Managing sessions & data¶
gdc saves your sessions, remembered approvals, and memory notes. This page shows how to inspect, clean up, and manage that data from the command line. All of these commands work without a model configured — they only read and edit local data.
Sessions¶
List¶
gdc sessions list # newest sessions in the current project
gdc sessions list --all # across every project
gdc sessions list --cwd /path # a specific project, without cd
gdc sessions list --limit 50 # more rows
By default the list is scoped to the project you're in (found by walking
up to a .git marker). Subagent sessions are shown too; hide or
structure them:
gdc sessions list --root-only # hide subagent sessions
gdc sessions list --tree # show the parent/child tree
Show¶
gdc sessions show <id> # full transcript
gdc sessions show <id> --limit 10 # just the last 10 messages
gdc sessions show <id> --json # machine-readable
Delete¶
Deleting a session also removes its messages and tool records. It asks
for confirmation unless you pass --yes:
Bulk cleanup¶
Remove every session older than a number of days:
gdc storage gc 30 --dry-run # preview how many would go
gdc storage gc 30 # delete (confirms first)
gdc storage gc 30 --yes # scripted
Remembered approvals¶
When you tell gdc to remember an approval, it's saved per project. Inspect and undo them:
gdc permissions list # this project's remembered approvals
gdc permissions list --all # every project
gdc permissions list --json # machine-readable
gdc permissions revoke bash jq # take back one approval
gdc permissions revoke --all # clear them all for this project
Revoking is idempotent — revoking something that isn't there succeeds quietly, so it's safe in scripts.
Memory notes¶
Manage your durable memory notes directly:
gdc memory list # all notes for this project
gdc memory list --scope user # just user-scope notes
gdc memory search redis # find by keyword
gdc memory show <name> # read a note
gdc memory write <name> \
--description "short summary" \
--type project --scope project \
--content "The staging database is read-only."
gdc memory delete <name> --scope project
The --type is one of user, feedback, project, or reference; the
--scope is user, project, or local. Pass --content - to read the
note body from standard input.
Machine-readable output¶
Most inspection commands accept --json and produce a stable shape you
can pipe into other tools:
Where the data lives¶
See Installation for the on-disk locations, and Configuration to change them.