Skip to content

feat: 新增 port skill —— 列出本地 web 服务并按 ID kill - #53

Merged
jhfnetboy merged 1 commit into
mainfrom
feat/port-skill
Aug 9, 2026
Merged

feat: 新增 port skill —— 列出本地 web 服务并按 ID kill#53
jhfnetboy merged 1 commit into
mainfrom
feat/port-skill

Conversation

@jhfnetboy

Copy link
Copy Markdown
Member

内容

新增仓库级 skill port.claude/skills/port/):

  • list:lsof 扫描 LISTEN 端口 → 并发探测 http/https → 抓取页面 title → 输出可点击 markdown 表格(ID/Title/URL/Port/进程/PID),ID 映射存入 ~/.cache/claude-port/state.json
  • kill <ID...>:按上次 list 的 ID 杀进程,支持多 ID 和区间(如 kill 1 3 5-8);kill 前重新扫描核对 pid/端口一致性,防 pid 复用误杀;默认 SIGTERM 等待确认,-9 强杀

已在本机实测:list 扫出 24 个服务,批量 kill 正常,pid 变化护栏正确拒绝。

@jhfnetboy
jhfnetboy requested a review from clestons as a code owner August 9, 2026 05:10
@jhfnetboy
jhfnetboy merged commit efb4b37 into main Aug 9, 2026
5 checks passed
@jhfnetboy
jhfnetboy deleted the feat/port-skill branch August 9, 2026 05:18
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant