explaingit

patrickjs/port-manager

Analysis updated 2026-07-18 · repo last pushed 2026-05-30

SwiftAudience · developerComplexity · 2/5MaintainedSetup · easy

TLDR

Port Manager finds free network ports on your machine and reserves them so your dev tools don't collide when running multiple local services.

Mindmap

mindmap
  root((repo))
    What it does
      Find free ports
      Reserve a port
      Track who holds it
      Shared lease registry
    Tech stack
      Swift
      CLI tool
      macOS app
      Node.js library
    Use cases
      Avoid dev server conflicts
      Coordinate AI coding agents
      Replace get-port portfinder
    Audience
      Developers
      AI coding agents
    Interfaces
      Command line
      Raycast
      Mac desktop app

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Ask for a free port near 3000 instead of manually checking for conflicts when running several local dev servers.

USE CASE 2

Let an AI coding agent spin up servers without guessing at open ports or parsing system commands.

USE CASE 3

Swap Port Manager in as a drop-in replacement for get-port or portfinder without rewriting code.

USE CASE 4

Coordinate a frontend build tool and a test runner so they don't both grab the same port.

What is it built with?

SwiftNode.jsCLImacOSRaycast

How does it compare?

patrickjs/port-manageraiduckman/claudeusage_latest_may2026arnabau/thermalpulse
Stars00
LanguageSwiftSwiftSwift
Last pushed2026-05-30
MaintenanceMaintained
Setup difficultyeasyeasymoderate
Complexity2/52/53/5
Audiencedevelopervibe coderdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min

macOS background service requires the desktop app, other interfaces (CLI, Node library) need no extra setup.

In plain English

Port Manager is a developer tool that finds available network ports on your machine, tells you what's using them, and lets you safely claim a port so another process won't grab it. Instead of wrestling with port conflicts when you're running multiple local services (a frontend dev server on 3000, a database on 5432, a test suite on 8080), you ask Port Manager "give me a free port near 3000" and it hands you one that's actually available, then holds it until you're done. The project is built as a hub-and-spoke system so multiple ways of using it (a command-line tool, code libraries, a macOS desktop app, even Raycast integration) all talk to the same underlying logic. You can call it from Node.js code, run it as a CLI command and parse JSON output, or click through a Mac app. All paths feed information to a shared "lease registry", essentially a file on disk that tracks which ports are claimed by which processes, so if your frontend build tool and your test runner both ask Port Manager for a port, they won't step on each other even if they run at slightly different times. The typical user is a developer with multiple local services running, or an AI agent (like GitHub Copilot or a custom coding assistant) that's spinning up servers and needs a way to find open ports without guessing or parsing obscure system commands. It's also built to play nice with existing Node.js packages like get-port and portfinder, you can swap Port Manager in without rewriting your code. A few details make this practical: you can reserve a port temporarily (a "soft" reservation that other cooperative tools will respect) or bind it for real (a hard lock that the OS recognizes). The macOS app can run as a background service that stays running between restarts, so it's always available to field port queries. And the whole thing is intentionally lightweight, it's not a firewall or a permission system, just a registry that helps well-behaved tools coordinate.

Copy-paste prompts

Prompt 1
Show me how to call Port Manager from Node.js to reserve a free port near 3000.
Prompt 2
Write a CLI command that asks Port Manager for an open port and parses the JSON output.
Prompt 3
Explain the difference between a soft reservation and a hard lock in Port Manager.
Prompt 4
Help me swap my project's get-port dependency for Port Manager without changing my code's behavior.
Prompt 5
Show me how to run the Port Manager macOS background service so it's always available.

Frequently asked questions

What is port-manager?

Port Manager finds free network ports on your machine and reserves them so your dev tools don't collide when running multiple local services.

What language is port-manager written in?

Mainly Swift. The stack also includes Swift, Node.js, CLI.

Is port-manager actively maintained?

Maintained — commit in last 6 months (last push 2026-05-30).

How hard is port-manager to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is port-manager for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.