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

claude-relink

v0.0.1

Published

Find missing Claude Code chats for the current directory and print resume commands.

Readme

claude-relink

claude-relink CLI hero image

claude-relink is a small read-only helper for finding missing or hard-to-locate Claude Code chats that match the current working directory and printing the command needed to resume them.

Use it when a Claude Code chat looks lost, missing from the /resume picker, or disconnected from the project you were working in, but the local Claude Code transcript still exists on disk.

This is especially for chats that no longer appear in the Claude Code /resume picker after you ran /clear or /new. Those commands do not delete the transcript — the .jsonl file stays on disk untouched. They just start a fresh session id, and the picker stops surfacing the old one. Run claude-relink latest or claude-relink list from the project directory, and it reads the project folder directly and ignores whatever the picker decided to show.

It reads local Claude Code storage:

  • ~/.claude/projects/<encoded-cwd>/<session-id>.jsonl

There is no database. Each session is a plain JSONL transcript, and the session id is the file name. The working directory it matches against is read from inside each transcript (the folder name is lossy and is not trusted), so it still finds chats whose project path contains a . directory such as ~/.t3/worktrees/....

It does not edit, move, or delete anything under ~/.claude. It only reads transcripts and their modification times.

Install

Install it globally from npm if you want the claude-relink command available everywhere:

npm install --global claude-relink

Then run it from the project directory whose Claude Code chats you want to find:

claude-relink latest
claude-relink list

You can also run it without installing anything globally:

npx claude-relink latest
npx claude-relink list

Or with Bun:

bunx claude-relink latest
bunx claude-relink list

All three forms use the current working directory as the project to match against local Claude Code storage.

Build

pnpm install
pnpm build

Latest Chat

From any project directory:

claude-relink latest

Or from this checkout without installing:

node dist/cli.js latest

The command finds Claude Code chats matching process.cwd(), selects the newest chat by transcript modification time, and prints:

  Copy the command below to resume your chat:

  claude --resume <session-id>

If there are no matching chats, it prints a short message for the current directory.

Pick A Chat

From any project directory:

claude-relink list

Or from this checkout without installing:

node dist/cli.js list

list shows an interactive picker, newest first. Rows are numbered so 1 is always the latest matching chat, and the picker stops at the oldest chat instead of wrapping around. Each row includes the number, updated time, short session id, and title or fallback. Press enter to select the highlighted chat. After selection, the accepted prompt line shows Chosen ID: <short-id> before it prints:

  Copy the command below to resume your chat:

  claude --resume <session-id>

Options

Show CLI help:

claude-relink -h
claude-relink --help

Use --claude-home when testing against another Claude home directory:

claude-relink --claude-home /tmp/claude-home latest

Normal use does not require any path flags; the current working directory is used automatically.

Author

Built by Warya Wayne, @waryawayne.