A tiny macOS menu bar app that shows which local ports are listening.
Every localhost dev server, database, and stray background tool — in one click.
- Live list of listening TCP ports — refreshed every few seconds.
- Knows what's running — shows the owning process, its pid, and the page title for local web servers.
- One click to open — hover a row to launch
http://localhost:<port>, or copy the address. - Stop a runaway process — graceful
SIGTERMto the validated owner, after you confirm. - Network-exposed warning — a 🌐 marks ports bound to
*, reachable beyond loopback. - Noise filter — system and background services are hidden behind a toggle.
- Grab
lilnet.app.zipfrom the latest release. - Unzip and drag
lilnet.appto/Applications. - The build is unsigned, so the first launch needs: right-click → Open → Open.
The icon appears in the menu bar — there is no Dock icon and no main window.
git clone https://github.com/adeoh/lilnet.git
cd lilnet
make bundle # produces lilnet.app
open lilnet.appmake run builds and launches in one step for development.
Requires macOS 14 (Sonoma) or later and a Swift 6 toolchain.
System Settings → General → Login Items → add lilnet.app.
PortScanner polls lsof -nP -iTCP -sTCP:LISTEN -F pcPnt, parses the
field-formatted output, and publishes a deduplicated list of ListeningPort
values. PortTerminator re-validates the pid/port pair immediately before
signalling, so a recycled pid never gets killed by mistake. The UI is pure
SwiftUI (MenuBarExtra) running as a menu-bar accessory.
No daemons, no network calls, no telemetry. Just lsof.
| File | Purpose |
|---|---|
Sources/lilnet/lilnetApp.swift |
App entry point + menu bar label |
Sources/lilnet/MenuContentView.swift |
Pop-over UI and port rows |
Sources/lilnet/PortScanner.swift |
lsof polling + parsing |
Sources/lilnet/ListeningPort.swift |
Model for one listening port |
Sources/lilnet/PortTerminator.swift |
Listener validation + graceful termination |
swift test # run the test suite- Remember a friendly name per port (e.g. "web", "api")
- Notifications when a new port opens
MIT — see LICENSE.