Gemini CLI
Gemini CLI is a historical import source. Hansard preserves existing saved chats and checkpoints, but does not offer or install a new live Gemini CLI workflow. Antigravity is the current Google-agent integration.
Source IDs
Section titled “Source IDs”| Source | Use it for |
|---|---|
gemini-cli |
Existing Gemini CLI history under the provider’s saved stores. |
How the import works
Section titled “How the import works”Hansard scans the provider-owned records below
~/.gemini/tmp/<project-id>/: saved chat JSON/JSONL, root manual checkpoints,
tool checkpoints, prompt logs, and one nested subagent level. It does not treat
shell history or user-selected exports as automatic conversations. User and
model messages, function calls and results, checkpoints, model information,
usage, and project context are normalized when the source recorded them.
Append-only JSONL is replayed before normalization. Repeated message ids replace earlier values, rewinds remove the selected turn and everything after it, and a whole-history snapshot replaces the current message set. When both a legacy hash directory and its copied project-slug directory survive, the provider session id selects one conversation and JSONL takes precedence over stale JSON.
Only durable records that remain in the provider store can be imported; Gemini CLI may already have pruned older or temporary files. Child sessions are kept as linked conversations rather than merged into the parent. This source exists to preserve historical Gemini CLI work and can be rerun to refresh those saved records. It is not a new live integration target; current Google-agent coverage is provided by the Antigravity importers.
Import and keep current
Section titled “Import and keep current”hansard import --source gemini-cli --since allhansard index rebuildUse the Antigravity guide for current CLI, 2.0, and IDE histories. No new Gemini CLI installation or runtime setup is required for a historical import.
Review the import in the app
Section titled “Review the import in the app”After the import finishes, open Conversations and selectFilter & sort. Set Source toGemini CLI, choose the backfill window underTime, and use Folder when the same harness appears in several projects. Select a result to inspect its messages, tool calls and results, files, commits, model and usage fields, and source provenance in one conversation view.
For a local source that should stay current, open Settings → Indexing & Imports. Automatic follows detected local harnesses; Custom lets Sources scannedselect an explicit set. Explicit cloud and account-export sources do not turn into background network jobs here. If the expected result is absent after resetting the conversation filters, return to the terminal import in this guide and add --explain-skips where supported.
What Hansard preserves
Section titled “What Hansard preserves”- Saved JSON and JSONL conversations, manual checkpoints, tool checkpoints, prompt logs, and linked subagent records.
- User and model turns, function calls and results, shell or code execution, usage metadata, title updates, and structured lifecycle data when recorded.
- Linked subagent sessions and parent invocation metadata.
- Provider shutdown summaries as session metadata rather than invented chat turns.
Known limitations
Section titled “Known limitations”- Gemini CLI retention settings may have pruned older provider files before Hansard imported them.
- User-selected
/chat shareand/export-sessionfiles are not automatic provider stores and require an explicit manual import workflow. - Hansard does not assume a stable Gemini CLI resume command.
- A historical record cannot gain fields the provider never persisted.
Refresh an existing archive
Section titled “Refresh an existing archive”The current parser revision narrows discovery to official upstream layouts and replays JSONL rewinds before normalization. Refresh existing Gemini archives from the provider records:
hansard import --source gemini-cli --since allhansard index rebuild