Neptune

A Raycast-style Spotlight launcher for macOS, built from scratch in Swift - global hotkey, a blur overlay window, fuzzy search, app launching, and an in-progress calculator mode.

I use Raycast every day and got curious how the actual mechanics work - a global hotkey that works from any app, a floating overlay window that doesn’t steal focus from whatever you were doing, fuzzy search fast enough to feel instant. So I started building the same category of launcher myself, from the hotkey up.

The overlay, without stealing focus

HotkeyService registers the global shortcut via CGEventTap, which is the same low-level mechanism system-wide hotkey tools use to intercept key events before any app gets them. The search window itself is a non-activating NSWindow with system vibrancy and blur - it appears without taking keyboard focus away from whatever was frontmost, and closes on escape or a click outside.

Where it stands

The build so far covers global hotkey activation, the overlay window itself, a search model with a results list, and app launching from those results. Calculator mode - detecting a math expression in the search field and evaluating it inline, the way Spotlight and Raycast both do - is the phase in progress now.

Key decisions

Built with