npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

copilot-session-sync

v0.1.2

Published

MCP server to sync GitHub Copilot sessions across machines via a private GitHub repo

Readme

copilot-session-sync

MCP server that syncs GitHub Copilot CLI and VS Code sessions across machines via a private GitHub repository.

How It Works

Your Copilot sessions live in ~/.copilot/session-state/ and ~/.copilot/session-store.db. This MCP server syncs them to a private {username}/.copilot repository on GitHub, so you can access the same sessions from any machine or Codespace.

  • Bidirectional sync — pushes new/updated local sessions and pulls new/updated remote sessions
  • Session-level merge — uses updated_at timestamps from workspace.yaml to determine which side wins
  • DB merge — row-level merge of the session-store.db SQLite database with FTS5 index rebuild
  • Auto-creates the .copilot private repo if it doesn't exist

Setup

Prerequisites

  • Node.js >= 20
  • GitHub CLI (gh) authenticated, or GITHUB_TOKEN environment variable

Install

cd copilot-sync
npm install
npm run build

Configure for GitHub Copilot CLI

Add to your Copilot CLI MCP configuration:

{
  "mcpServers": {
    "copilot-session-sync": {
      "command": "node",
      "args": ["/path/to/copilot-sync/dist/index.js"],
      "env": {}
    }
  }
}

Configure for VS Code

Add to your VS Code settings.json:

{
  "mcp": {
    "servers": {
      "copilot-session-sync": {
        "command": "node",
        "args": ["/path/to/copilot-sync/dist/index.js"]
      }
    }
  }
}

MCP Tools

sync_sessions

Bidirectional sync of all sessions. Compares local and remote by session ID and timestamps.

| Parameter | Type | Description | |-----------|------|-------------| | dry_run | boolean (optional) | Preview what would be synced without making changes |

list_remote_sessions

Lists all sessions (local and remote) with their sync status.

| Parameter | Type | Description | |-----------|------|-------------| | filter | string (optional) | Filter by summary text or repository name |

Status icons:

  • ✅ Synced
  • 📤 Local only
  • 📥 Remote only
  • ⬆️ Local newer
  • ⬇️ Remote newer

pull_session

Pull a specific session from the remote repo.

| Parameter | Type | Description | |-----------|------|-------------| | session_id | string (required) | UUID of the session to pull |

push_session

Push a specific local session to the remote repo.

| Parameter | Type | Description | |-----------|------|-------------| | session_id | string (required) | UUID of the session to push |

sync_status

Show sync status overview — last sync time, session counts, what needs syncing.

Usage Examples

From Copilot CLI or VS Code chat:

> Sync my copilot sessions
> Show me what sessions need syncing
> List my remote sessions
> Pull session abc12345-...
> Push the current session to remote

Environment Variables

| Variable | Description | Default | |----------|-------------|---------| | GITHUB_TOKEN | GitHub personal access token | Falls back to gh auth token | | GITHUB_USER | GitHub username | Auto-detected from token | | COPILOT_HOME | Path to Copilot config directory | ~/.copilot | | COPILOT_SYNC_REPO | Name of the sync repository | .copilot |

Architecture

~/.copilot/
├── session-state/          ← synced
├── session-store.db        ← synced (row-level merge)
├── sync-cache/             ← local clone of the remote repo
├── config.json             ← NOT synced (machine-specific)
└── logs/                   ← NOT synced

The sync cache (~/.copilot/sync-cache/) is a local git clone of the remote repo. It's reused across syncs for efficiency.

License

MIT