<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[NanYuJun]]></title><description><![CDATA[NanYuJun]]></description><link>https://nanyujun.hashnode.dev</link><generator>RSS for Node</generator><lastBuildDate>Tue, 24 Nov 2026 12:08:57 GMT</lastBuildDate><atom:link href="https://nanyujun.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Keeping AI coding agent sessions in sync across machines]]></title><description><![CDATA[A self-hosted hub that syncs Claude Code, Codex and Cursor session history across machines — plus the limits that still hurt.]]></description><link>https://nanyujun.hashnode.dev/keeping-ai-coding-agent-sessions-in-sync-across-machines</link><guid isPermaLink="true">https://nanyujun.hashnode.dev/keeping-ai-coding-agent-sessions-in-sync-across-machines</guid><category><![CDATA[AI]]></category><category><![CDATA[claude]]></category><category><![CDATA[Open Source]]></category><category><![CDATA[Productivity]]></category><dc:creator><![CDATA[南羽]]></dc:creator><pubDate>Mon, 02 Nov 2026 06:00:10 GMT</pubDate><content:encoded><![CDATA[<p>I work across more than one machine, and I switch between coding agents depending on the task: Claude Code, Codex CLI, Cursor, Gemini CLI. The models keep getting better, but the context is still nailed to one laptop.</p>
<p>Every agent stores its history differently, and locally:</p>
<ul>
<li>Claude Code keeps CLI transcripts under <code>~/.claude/projects/&lt;encoded-project-path&gt;/&lt;session-id&gt;.jsonl</code></li>
<li>Other agents have their own session directories and formats</li>
<li>Cursor keeps chat state inside its workspace storage</li>
</ul>
<p>Copying the project folder is not enough, because session files live outside it. Copy them to a new machine and the paths may not match either. So "continue where I left off" turns into manual file archaeology.</p>
<p>I built AIAssets to fix that for my own workflow.</p>
<h2>What it does</h2>
<p>AIAssets is a self-hosted hub. On each machine it scans the session files of the agents it supports, indexes them, and syncs the index and session data bidirectionally through the hub on a 60-second poll. Session titles are preserved, so you can find the thread you were in. Over that index it also gives you search, share, and backup.</p>
<p>Self-hosting is a deliberate choice: transcripts contain source code, internal URLs, and sometimes commands with credentials in them. I did not want a third-party service holding all of that.</p>
<h2>Support and current limits</h2>
<p>The README lists 10 agents with read/write support, including Claude Code, Codex, Cursor, and Gemini CLI. It is early software, so the limits matter more than the feature list:</p>
<ul>
<li>v1.0.0 ships a Windows installer only.</li>
<li>On macOS you build the DMG from source with <code>pnpm run build:mac</code>; it is not signed, so Gatekeeper will complain.</li>
<li>Sync is polling, not real-time.</li>
<li>There is no conflict UI yet. If you continue the same session on two machines, I do not have a good merge story.</li>
<li>Agent updates change session formats, and parsers break.</li>
</ul>
<h2>The parts I am unsure about</h2>
<p><strong>1. Project path mapping.</strong> A session is tied to a working directory. If machine A uses <code>/Users/me/code/foo</code> and machine B uses <code>D:\code\foo</code>, restoring on B can show the session but fail to resume because the cwd does not exist. Should the hub rewrite paths, or store a logical project ID? I lean toward the latter, but it is not shipped.</p>
<p><strong>2. Divergent branches.</strong> The same session continued on two machines creates two files. Last-write-wins loses one side. A real merge of JSONL transcripts is harder than it sounds, and I would rather not fake it.</p>
<p><strong>3. Size and transport.</strong> Sessions can get large. Polling the full hub every 60 seconds is fine on a LAN and wasteful over a metered connection. Incremental transfer is on the list.</p>
<h2>Repo</h2>
<p><a href="https://github.com/NanYuJun/AIAssets">https://github.com/NanYuJun/AIAssets</a></p>
<p>If you run more than one machine or more than one agent, I would rather hear which part breaks first than get a star. Issues with your setup — OS, agents, where the sessions live — are more useful than "doesn't work".</p>
]]></content:encoded></item></channel></rss>