How sindresorhus/fkill-cli works
fkill-cli is a cross-platform process-killing command-line app. A user supplies process IDs, names, or colon-prefixed ports for direct termination, or runs it without arguments to browse and search a live process list, select a process, and confirm termination. The interactive path enriches process records with port ownership, filters and sorts them, and can prompt to force-kill survivors. The graph reflects the supplied CLI and interactive source; process discovery and termination are external dependencies, so their internal behavior is not expanded.
Main entry points: interactive.js Interactive setup · cli.js CLI dispatcher
Components 17
CLI entry
- CLI dispatcher
cli.js
Interactive workflow
- Interactive setup
interactive.js - Process inventory
interactive.js - Port enrichment
interactive.js - Search and sort
interactive.js - Process picker
interactive.js - Kill sequence
interactive.js - Exit polling
interactive.js - Force prompt
interactive.js
Runtime integrations
- Argument parser
- fkill engine
- Process listing
- Port lookup
- Search prompt
- Process existence
- Terminal UI
Other components
- CLI user
Connections 20
- CLI user → CLI dispatcher: invokes
- CLI dispatcher → Argument parser: parses arguments
- CLI dispatcher → fkill engine: kills requested targets
- CLI dispatcher → Interactive setup: starts without targets
- CLI dispatcher → Interactive setup: delegates kill errors
- Interactive setup → Process listing: lists processes
- Interactive setup → Port lookup: maps ports to PIDs
- Interactive setup → Port enrichment: enriches process records
- Port enrichment → Process inventory: passes enriched records
- Interactive setup → Process inventory: provides process records
- Process inventory → Search and sort: filters and sorts
- Search and sort → Process picker: supplies matching choices
- Process picker → Search prompt: prompts for selection
- Process picker → Kill sequence: submits selected PID
- Kill sequence → fkill engine: attempts termination
- Kill sequence → Exit polling: checks survivors
- Exit polling → Process existence: checks PID existence
- Kill sequence → Force prompt: asks about force kill
- Force prompt → Terminal UI: prompts or reports
- Force prompt → fkill engine: force-kills if confirmed