Skip to content

A CLI tool to kill processes running on specified ports.

License

Notifications You must be signed in to change notification settings

luckfunc/kill-port-process-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

kill-port-process-cli

A CLI tool to kill processes by port. This tool allows you to terminate processes running on specified ports. It is useful for developers who need to quickly free up ports during development.

Installation

To install the package globally, use npm:

npm install -g kill-port-process-cli

Usage

You can use the tool by running the k or k-p or kill-port command followed by one or more port numbers.

Recommended Command

We recommend using the k command for simplicity and ease of use.

example

To kill processes running on ports 3000 and 3001:

k 3000 3001

or

k-p 3000 3001

or

kill-port 3000 3001

Compatibility

This tool is compatible with Windows, macOS, and Linux.

How It Works

  1. The tool identifies the process ID (PID) using the specified port.
  2. It then terminates the process associated with that PID.

Finding the PID

  • On Unix-based systems, it uses the lsof command.
  • On Windows, it uses the netstat command.

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

About

A CLI tool to kill processes running on specified ports.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published