Skip to content

dinakars777/port-sniper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

port-sniper 🎯

npm version npm downloads License: MIT

A blazing fast, beautiful CLI tool to instantly identify and kill processes hoarding your local development ports.

Getting EADDRINUSE: address already in use :::3000 multiple times a day? You usually have to Google lsof -i :3000, copy the PID, and type kill -9 <PID>. port-sniper automates this into a single, satisfying command.

Features

  • ✨ Zero configuration — just type snipe <port>
  • 🎨 Beautiful UI powered by @clack/prompts
  • ⚡ Lightning fast — uses native lsof and kill -9 under the hood
  • 🛡️ Interactive safety prompt before killing anything

Quick Start

npx @dinakars777/port-sniper 3000

Or install globally for the short snipe alias:

npm install -g @dinakars777/port-sniper
snipe 3000
snipe 8080

How It Works

  1. Searches for processes bound to the provided port
  2. If the port is free, exits cleanly
  3. Displays the Command, PID, and User owning the process
  4. Prompts Kill this process? [y/N] before doing anything
  5. Executes a forceful termination and frees your port

Tech Stack

Package Purpose
@clack/prompts Beautiful interactive CLI UI
execa Native process execution
TypeScript Type-safe implementation

Contributing

git clone https://github.com/dinakars777/port-sniper.git
cd port-sniper
npm install
npm run dev

License

MIT

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors