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

dsh-codex-continue

v0.2.2

Published

DSH plugin: browse local Codex projects & sessions and continue them in DSH — read ~/.codex rollouts, pick a session, resume with full context (goal + transcript + cwd).

Readme

dsh-codex-continue

DSH 插件:读取本机 OpenAI Codex 的项目与会话,在 DSH 里无缝「继续」——Codex 5 小时限额到了,活不丢,换个环境接着干。

在 DSH(DeepSeek Harness)里浏览你的 Codex 历史会话(~/.codex/sessions/*.jsonl,只读),选中任意会话后生成一份「续作包」——目标 + 最后消息 + 压缩正文 + 项目目录 + git 状态——交给 DSH agent,让它以原工作目录为基准继续完成 Codex 没做完的工作。

特性

  • 📂 项目/会话浏览:按工作目录聚合项目,标题(来自 session_index.jsonl)、时间、模型、消息数一目了然;支持搜索
  • 🔎 会话预览:goal / 最后消息 / 分色正文(你 / Codex / 思考 / 工具调用)
  • ⚡ 续作包 resume bundle:token 预算内压缩正文(工具输出截尾、reasoning 只留摘要、按 callId 配对),附 cwd 存在性与 git status
  • ✍️ 一键继续:侧边栏点「⚡ 继续此会话」直接把续作指令注入输入框(不再需要复制粘贴);「📄 RESUME.md」在项目目录生成交接文档(换 agent / 给人看 / 跨机迁移都可用)
  • 🧰 两种用法:直接在对话里指挥 agent 调 codex 工具(主路径),或侧边栏「Codex 续作」Tab 浏览后点继续(需 dsh-better-sidebar)
  • 🔍 浏览体验:项目/会话搜索、刷新、归档标记、goal/最后消息预览
  • 🔒 安全:只读 rollout JSONL + 索引;绝不读 auth.json / config.toml / sqlite

安装

# 在运行 DSH web 的机器上
dsh plugin --profile web add dsh-codex-continue
# 重启 dsh web 生效

⚠️ 插件发布后 24 小时内,pnpm 11 的供应链策略(minimumReleaseAge=1440)会拦截安装;此时请在命令后加 --config.minimumReleaseAge=0(单次生效,不改任何配置)。

侧边栏 UI 需要 dsh-better-sidebar(没有也能用——codex 工具始终可用)。

使用

方式一:直接跟 Agent 说(推荐)

继续我的 Codex 会话《设计会话同步工具》,先看看现场再接着做。

Agent 会调 codex(action: resume) 拉回续作包,切到原项目目录核对现场后继续。

方式二:侧边栏浏览

右侧边栏 →「✦ Codex 续作」Tab → 项目 → 会话 → 预览 →「⚡ 继续此会话」(续作指令直接注入输入框,回车即发送);「📄 RESUME.md」在项目目录生成交接文档。

codex 工具

| action | 说明 | |---|---| | list_projects | 按工作目录聚合的项目列表 | | list_sessions | 会话列表(query / project 过滤) | | show_session | goal + 最后消息 + 预览片段 | | resume | 完整续作包(目标/正文/cwd/git/统计),即上下文注入点 | | resume_doc | 在项目目录生成 RESUME.md 交接文档 |

配置

cordis.patch.yml 的 config 块(或 profile 的 patch 层覆盖):

| key | 默认 | 说明 | |---|---|---| | codexHome | ~/.codex | Codex 数据目录 | | maxBundleTokens | 60000 | 续作包正文 token 预算 | | toolOutputTail | 400 | 工具输出保留尾部字符数 | | argsPreview | 200 | 工具参数预览长度 | | messageMax | 2000 | 单条消息在正文中的字符上限 | | includeGitStatus | true | 续作时跑 git status | | maxAgeDays | 0 | 只列出最近 N 天的会话(0=全部) | | resumeDocName | RESUME.md | 交接文档文件名(写入项目目录) |

数据来源(只读)

  • ~/.codex/sessions/YYYY/MM/DD/rollout-*.jsonl —— 会话正文(JSONL 事件流)
  • ~/.codex/session_index.jsonl —— 标题/时间索引(id 与 rollout 的 session_id 同键)
  • 项目 = 会话的 cwd

开发

pnpm install
pnpm test        # vitest(解析/索引/续作包)
pnpm typecheck
pnpm build       # tsc host + tsdown client bundle
./scripts/sync-installed.sh   # 把构建同步进 web profile 的安装副本(见下)

本地开发注意:profile 的 pnpm 用 nodeLinker: hoisted,file: 依赖是复制进 node_modules 的(不是软链)——pnpm build 后必须跑 scripts/sync-installed.sh 同步(或重新 install)。client 改动同步后浏览器强刷即可,无需重启 DSH;host 改动仍需重启。

客户端 bundle 注意事项:client 半区必须以 CJS + window.__ModuleLoader__.load({id, factory}) 形式打包注册(见 tsdown.config.ts 的 banner/footer),否则浏览器侧不会激活;build 末尾的 verify-client-bundle.mjs 会在 VM 里模拟加载器做回归校验。host 半区读配置必须用 apply(ctx, rawConfig) 的第二参数,不能读 ctx.config。

设计文档见 DESIGN.md;可交互界面原型见 ui-mockup/;解析原型见 poc/。

发布(npm)

CI 已配置:打 v* tag 自动构建并发布(需仓库 NPM_TOKEN secret)。

npm login                          # 本机登录(一次性)
git tag v0.2.1                     # 版本号与 package.json 一致
git push origin v0.2.1             # CI 自动发布
npm view dsh-codex-continue         # 验证

建议在发布后满 24 小时之前不要期望别人能立刻安装成功:pnpm 11 默认 minimumReleaseAge=1440(24h),刚发布的包会被供应链策略拦截。

License

MIT