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-remote-login

v0.2.1

Published

Dispatch opencode sessions to remote hosts via SSH. Migrate context, execute tasks remotely, and optionally pull results back.

Readme

opencode-remote-login

Dispatch opencode sessions to remote hosts via SSH. Migrate context, execute tasks remotely, and optionally pull results back.

Install

opencode plug -g opencode-remote-login

Use -g to install globally into ~/.config/opencode/opencode.jsonc. Without -g, the plugin is installed into the current project's .opencode/ directory instead.

Configure hosts

Host config is loaded from these locations (later files override earlier):

  1. Global: ~/.config/opencode/hosts.json (or hosts.jsonc)
  2. Project: <projectDir>/hosts.json (or hosts.jsonc)
  3. Project: <projectDir>/.opencode/hosts.json (or hosts.jsonc)

Inline plugin options take the highest priority. JSONC (comments, trailing commas) is supported everywhere.

Create ~/.config/opencode/hosts.json:

{
  "hosts": {
    "dev-box": {
      "host": "[email protected]",
      "port": 2222,
      "os": "linux",
      "agent": "build",
      "model": "opencode/big-pickle"
    }
  }
}

Alternatively, configure inline in opencode.jsonc:

{
  "plugin": [
    ["opencode-remote-login", {
      "hosts": {
        "dev-box": { "host": "[email protected]" }
      }
    }]
  ]
}

Host fields

| Field | Required | Description | | ------- | -------- | ------------------------------------------------ | | host | Yes | SSH address (user@host) | | port | No | Custom SSH port (default: 22) | | os | No | linux or windows; auto-detected if omitted | | agent | No | Override agent on the remote | | model | No | Override model in provider/id format |

Only host names are shown to the LLM. SSH addresses stay on disk.

SSH setup

ssh-copy-id [email protected]

Password prompts are not supported. Configure key-based SSH access before dispatching a session.

Windows hosts

Windows remotes are supported via OpenSSH and PowerShell. Set "os": "windows" in host config to skip auto-detection, especially when using a custom SSH port.

Windows round-trip dispatch uses Task Scheduler (schtasks) instead of detached child processes. This avoids Windows OpenSSH killing child processes when the SSH session exits.

Requirements on the Windows host:

  • OpenSSH server with key-based login
  • powershell.exe and schtasks.exe
  • opencode available in the user's PATH

If round-trip times out, check the diagnostic logs printed by the tool. They are written under the remote %TEMP% directory and include launcher, runner, and command logs.

Usage

You can ask naturally. opencode will call remote_login when the task should move to a configured remote host.

Examples:

Use dev-box to fix the auth bug.
Run this on gpu-box and continue there.
Use windows-box, finish the task, then bring the result back here.
Debug this on dev-box in /home/dev/projects/app.

Help

Ask the LLM how to configure hosts, or call the tool directly:

How do I set up remote hosts?

One-way

Use one-way handoff when the work should continue on the remote host and the local conversation should stop.

Use dev-box to finish this task.
Move this session to gpu-box and continue there.

Round-trip

Use round-trip when the remote host should do the work and then merge the updated session back locally. The original agent and model are restored automatically on return.

Use dev-box to find the memory leak, then bring the result back.
Run this on windows-box and return here when done.

Target directory

Use dev-box in /home/dev/projects/app to fix the build.

Omit to default to ~.

Direct tool calls such as remote_login host=dev-box mode=round-trip also work, but they are optional.

How it works

local                                      remote
-----                                      ------
export session JSON
patch agent/model per host config  --->    SCP + import session
                                           run opencode on remote
                                           Linux: nohup
                                           Windows: schtasks runner
[round-trip] poll for completion     <---  export session JSON
[round-trip] restore agent/model
[round-trip] import back