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

@jiyr0119/dsh-service-console

v0.4.1

Published

DeepSeek Harness 本地开发服务控制台(原生插件):发现监听端口,识别服务归属,安全查看/停止/重启。Local development service console for DSH.

Readme

DSH Service Console

English | 简体中文

License npm npm downloads Awesome DSH Plugin Last commit GitHub stars

A local development service console for DSH: discover listening ports, identify services related to the current conversation or workspace, and safely inspect, stop, or restart them.

DSH 本地开发服务控制台:发现监听端口,识别与当前对话或工作区相关的服务,并安全地查看、停止和重启。

面向 DeepSeek Harness Web UI 的单职责插件。当模型(或你)启动本地开发服务(npm run dev、Vite、Next.js、Uvicorn、Express、Rust 等)时,Service Console 在一个地方把它们展示出来:监听了哪些端口、由什么命令和目录启动、是否属于当前对话或工作区、能否安全停止或重启。

功能

  • 服务发现 — 扫描监听 TCP 端口,关联 PID、PPID、命令、工作目录、进程组与启动时间(macOS/Linux)。
  • 归属与风险 — 五级归属:本次对话(与会话启动台账匹配)、工作区本机其他未知受保护
  • 受控操作 — 对进程组优雅停止;对保存了安全启动命令的服务重启。每个动作均二次确认,并在操作前重新校验快照。
  • 安全防护 — 任何信号前校验 PID 复用 / fingerprint;未知与受保护服务只读;强制终止默认关闭;无隐式自动清理;命令输出脱敏。
  • 全量本机服务 — 展示本机全部监听服务;归属只作为安全提示,不再隐藏端口分类,用户可自行选择要查看或停止的服务。
  • 搜索 / 配置 / 国际化 — 支持关键字过滤、优雅超时 / 强制终止设置;中英文界面自动跟随 DSH 当前语言。
  • 按需扫描 — 打开控制台时获取一次当前快照;点击刷新按钮才会主动重新扫描,不进行后台定时轮询。
  • DSH 原生检查卡片 — 展开详情采用 DSH Web token 化视觉风格,展示进程身份、端口、命令、工作目录和归属证据。

安装

原生安装(推荐):

dsh plugin --profile web add -w @jiyr0119/dsh-service-console@latest

安装后刷新 DSH Web UI——会话头部出现 🖥 SC 入口,点击打开控制台面板。

注意:插件被 dsh-market/awesome 收录 ≠ 浏览器自动出现 UI。本包同时提供 Host 路由与浏览器 bundle,dsh plugin add 后面板即可用。支持 macOS / Linux;Windows 暂不支持。

备用方式——动态粘贴(零构建、进程级):通过动态 Cordis 插件流程粘贴 dynamic/host.js + dynamic/client.js

界面预览

Service Console 0.2.0:全量本机服务与 DSH 风格检查卡片

预览展示本机完整监听服务列表与展开后的检查卡片。归属徽标仍作为安全提示保留,但列表不再按对话 / 工作区 / 本机拆分隐藏服务。

→ 交互式演示 — 无需安装即可在浏览器中体验 Service Console 界面。

权限与安全

  • Client 不直接传任意 PID 或 Shell 命令,只以 service ID 为目标,Host 在操作前重新校验 PID / 启动时间 / fingerprint。
  • 优先优雅终止(SIGTERM 到进程组);SIGKILL 仅在显式开启并确认后使用。
  • 命令摘要中的敏感 token/密码会脱敏。
  • 本插件不是通用进程管理器:系统关键、高权限、未知和受保护进程一律只读。

开发

pnpm install
npm run typecheck
npm run build
npm test          # 单元 + 集成测试(node --test)

测试

npm test 会先构建一次,再用 Node 内置测试运行器(node --test)执行整个测试套件,无需额外测试框架。

| 文件 | 类型 | 覆盖内容 | | --- | --- | --- | | test/process-inspector.test.mjs | 单元测试 | 平台输出解析(parseLstartparseListenRowsparsePsRowsparseAddress)、命令脱敏、五级归属分类 | | test/host-more.test.mjs | 单元测试 | 配置校验、会话台账、基于 fake 依赖的生命周期状态机(停止/重启)、服务聚合与 fingerprint 稳定性 | | test/integration.test.mjs | 集成测试 | 真实系统命令 + 测试自建的临时 HTTP 服务;只对测试自有进程发信号 |

npm test                                                       # 全部用例
npm run build && node --test test/process-inspector.test.mjs   # 单独运行某个文件

单元测试直接 import 构建产物(lib/),因此需要先编译源码——npm test 会自动完成。

许可证

MIT