返回资讯中心
外部精选
软件工程
#社区热议

Show HN: Proc-CLI – An agent-friendly CLI tool for process and port management

proc is a semantic CLI tool for process management on macOS, Linux and Windows. Find what's on a port, why it's there, and stop it, in one command you'd guess on the first try.

Hacker Newsyazeedaloyoun2026/10/26 · 今天26 分钟阅读

以下正文同步自 Hacker News,版权归原站所有,已转换为易读排版。

proc is a semantic CLI tool for process management on macOS, Linux and Windows. Find what's on a port, why it's there, and stop it, in one command you'd guess on the first try.

Ends whatever is listening on port 3000 immediately (SIGKILL). Asks first, and --dry-run previews.

A leading colon means a port: proc acts on whatever is listening on it.

Ends whatever is listening on port 3000 immediately (SIGKILL). Asks first, and --dry-run previews.

A leading colon means a port: proc acts on whatever is listening on it.

Ends process 1234 immediately, and nothing else.

A number is a PID: that one process and nothing else.

Ends every node process, after listing them and asking.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Ends all of them in one go, after one confirmation.

Commas combine targets. A process matched twice is only acted on once.

Ends only this folder's node processes, not your editor's or another project's.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Shows what's listening on port 3000: its name, PID, folder, CPU, memory and how long it has been running.

A leading colon means a port: proc acts on whatever is listening on it.

Works the other way too: shows process 1234 and every port it listens on.

A number is a PID: that one process and nothing else.

Shows each node process and the ports it listens on.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Answers all three at once: what's on ports 3000 and 8080, and which ports the node processes hold.

Commas combine targets. A process matched twice is only acted on once.

Shows only the node processes started in this folder, and their ports.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Traces what's on port 3000 back through its parent processes, so you see what started it: a terminal tab, a tmux session, your editor.

A leading colon means a port: proc acts on whatever is listening on it.

Shows the chain of parents that led to process 1234, with how long each one has been running.

A number is a PID: that one process and nothing else.

Traces every node process back to whatever started it.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Traces what holds ports 3000 and 8080, one chain each.

Commas combine targets. A process matched twice is only acted on once.

Finds the processes running server.py from this folder.

With proc for, the target is a file: relative, absolute or starting with ~.

Finds whatever has app.log open, such as a server that's still writing to it.

With proc for, the target is a file: relative, absolute or starting with ~.

Lists every process whose name or command line matches node.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

The same, limited to processes started in this folder.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Lists everything started in this folder or below it.

With proc in, the target is a folder. . is the one you're in.

Lists everything started in ~/code/shop, wherever you run it from, even after the folder has been deleted.

With proc in, the target is a folder. . is the one you're in.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Lists zombie processes: ones that have exited but haven't been cleaned up by their parent.

Flags narrow any listing. --status takes running, sleeping, stopped or zombie.

Shows everything about process 1234: folder, path, user, parent, status, CPU, memory and uptime.

A number is a PID: that one process and nothing else.

Shows everything about whatever is listening on port 3000.

A leading colon means a port: proc acts on whatever is listening on it.

Shows the full details of each node process.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Lists every listening port and the process behind it.

No target: proc looks at every listening port.

Only the ports other machines can reach, the ones worth checking.

--exposed keeps ports listening on 0.0.0.0 or ::, and --local the localhost ones.

Only the ports held by processes started in this folder.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Shows every process as a tree of parents and children.

Shows each node process with the processes it started.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Goes up instead of down: from process 1234 to the first process the system started.

A number is a PID. --ancestors turns the tree upside down.

Finds processes whose parent has exited, like dev servers left behind by a closed terminal. System services are left out.

No target: proc looks at every process whose parent has gone.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Ends this folder's orphans, after showing the list and asking.

--kill acts on what was found, and asks first like proc kill.

Finds processes that have been running for over 5 minutes and are using more than half a CPU right now.

Ends the stuck processes, after showing the list and asking.

--kill acts on what was found, and asks first like proc kill.

Ends whatever is listening on port 3000 immediately (SIGKILL). Asks first, and --dry-run previews.

A leading colon means a port: proc acts on whatever is listening on it.

Ends process 1234 immediately, and nothing else.

A number is a PID: that one process and nothing else.

Ends every node process, after listing them and asking.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Ends all of them in one go, after one confirmation.

Commas combine targets. A process matched twice is only acted on once.

Ends only this folder's node processes, not your editor's or another project's.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Asks whatever is on port 3000 to exit (SIGTERM), so it can clean up, and forces it after 10 seconds if it hasn't.

A leading colon means a port: proc acts on whatever is listening on it.

Stops process 1234 the same way: politely first, by force only if needed.

A number is a PID: that one process and nothing else.

Stops every node process gracefully, after asking.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Stops only the node processes started in this folder.

--in keeps any target inside a folder and the folders below it. Most commands take it.

Sends HUP instead of SIGTERM, which many servers take as “reload your config”.

A leading colon means a port. --signal picks the first signal sent.

Ends whatever holds port 3000, politely and then by force, and waits until the port is really free before saying so.

A leading colon means a port: proc acts on whatever is listening on it.

proc free only takes ports. Commas combine them.

Pauses every node process (SIGSTOP) without ending them, until you thaw them. macOS and Linux.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Pauses process 1234, handy for a heavy build while you need the machine back.

A number is a PID: that one process and nothing else.

Pauses whatever is on port 3000. Connections to it hang until you thaw it.

A leading colon means a port: proc acts on whatever is listening on it.

Resumes the node processes you froze (SIGCONT), right where they stopped.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

Resumes process 1234, whether proc freeze or Ctrl+Z paused it.

A number is a PID: that one process and nothing else.

Finds stuck processes and tries to recover them: wakes them (SIGCONT), then interrupts them like Ctrl+C. Nothing is ended without --force.

Tries to recover process 1234 the same gentle way, if it's stuck.

A number is a PID: that one process and nothing else.

If gentle recovery fails, ends the stuck node processes (SIGTERM, then SIGKILL).

Anything else is a name. --force allows ending it as a last resort.

A live table of every process, busiest first, refreshed every 2 seconds. Press q to quit.

Anything else is a name, matched against each process's name and full command line, so node also finds nodemon and node server.js.

A leading colon means a port: proc acts on whatever is listening on it.

Waits until whatever is on port 3000 has exited, so a script can start the next server.

A leading colon means a port: proc acts on whatever is listening on it.

A number is a PID: that one process and nothing else.

Gives up after 60 seconds if the node processes are still running, so CI doesn't hang.

Anything else is a name. --timeout gives up after that many seconds and exits 1.

Version 1.14.5. Also on npm, cargo, Scoop, Nix and Docker.

The same jobs, without remembering which flags lsof needs or piping PIDs into kill.

Every command takes the same targets, and almost all take --in to stay inside one project, --json for scripts, and --dry-run before anything changes.

Every command prints one JSON document with --json, and exit codes always mean the same thing. An agent can read proc the way you do, without parsing tables.

❯ proc on :8080 --json | jq '.process | {pid, cwd, uptime_secs}' { "pid": 177, "cwd": "/home/dev/code/shop", "uptime_secs": 35 }

Posts

What's new in proc: nineteen releases since March October 25, 2026

Unix signals: the complete reference March 10, 2026

nohup vs disown vs &: running background processes March 10, 2026

Managing child processes in Node.js March 10, 2026

All posts

正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。

打开原文
去社区讨论 →