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

opencode-session-migrate

v0.2.1

Published

opencode TUI plugin to migrate (re-parent) sessions across projects and rescue orphaned sessions

Readme

opencode-session-migrate

A opencode TUI plugin to migrate sessions between projects and rescue orphaned sessions.

Features

  • List sessions across all projects, not just the current one.
  • Detect orphaned sessions (directory no longer exists on disk, or a global session whose directory lives inside a known project worktree).
  • Migrate a session to another project, worktree, or your home directory.
  • Migrate child (forked) sessions along with the parent.

Requirements

  • opencode >=1.18.0 (TUI plugin API)

Installation

npm

opencode plugin -g opencode-session-migrate

Or add it to your tui.json:

{
  "$schema": "https://opencode.ai/tui.json",
  "plugin": ["opencode-session-migrate"]
}

Local path

Point directly at the plugin file:

{
  "$schema": "https://opencode.ai/tui.json",
  "plugin": [
    ["/path/to/opencode-session-migrate/src/index.tsx", { "keybind": "ctrl+o" }]
  ]
}

Restart opencode after changing your config.

Usage

  • Press ctrl+o anywhere, or run /migrate (or find "Migrate sessions" in the command palette).
  • Pick a session, then a destination: the current project, your home directory, or any other project.

Options

| Option | Type | Default | Description | |-----------|---------|------------|----------------------------------------------------------| | enabled | boolean | true | Set to false to disable the plugin. | | keybind | string | "ctrl+o" | Key binding that opens the migrate dialog. | | debug | boolean | false | Write debug logs to /tmp/opencode-session-migrate.log. |

How it works

  • Orphans are detected client-side by checking whether each session's directory still exists on disk, or whether a global session's directory lives inside a known project worktree.
  • Migration updates project_id and directory (and clears path/workspace_id) directly in the opencode SQLite database, including child sessions.

Limitations

  • Migration writes straight to the database, bypassing opencode's event system. The built-in session list may stay stale until a resync or restart; the plugin re-lists correctly on its own.
  • The ctrl+o hint does not appear in the built-in session list footer (the plugin API does not allow extending it). Use the command palette or /migrate if you forget the binding.

License

MIT