Nanobrew: The fastest macOS package manager compatible with brew
Nanobrew, a new macOS package manager written in Zig, claims to be up to 7,000x faster than Homebrew by leveraging advanced system features and parallel processing. This technical feat sparked intense debate on HN, primarily questioning the definition and extent of its
The Lowdown
Nanobrew introduces itself as the "fastest macOS package manager," built with Zig, promising installation speeds up to 7,000 times faster than Homebrew. It aims to streamline the package management experience on macOS through innovative technical approaches, positioning itself as a high-performance alternative to traditional tools.
- Blazing Speed: Achieves a claimed 3.5ms warm install time, leveraging native HTTP, parallel processing, and an APFS clonefile mechanism for copy-on-write materialization.
- Zero Overhead: Utilizes APFS clonefile for zero disk overhead per install and a single static ~2MB binary, eliminating Ruby runtime dependencies.
- Efficient Operations: Features BFS parallel dependency resolution, streaming SHA256 verification during downloads, and native Mach-O parsing to avoid external tools.
- Content-Addressing: Employs a SHA256-keyed content-addressed store for deduplication, ensuring re-installs skip download and extraction.
- Simple Interface: Provides familiar commands like
nb installandnb updatefor ease of use.
Nanobrew positions itself as a compelling solution for macOS users frustrated with the performance of existing package managers, promising a significantly snappier experience.
The Gossip
Compatibility Concerns
The central point of contention in the comments revolves around Nanobrew's claim of "compatibility with brew." Many, including the Homebrew project lead, argue that without executing Homebrew's Ruby-based formulae, it cannot be fully compatible, merely acting as a faster frontend to Homebrew's existing infrastructure (like its CDN and APIs). This raises concerns about potential fragility if Homebrew's underlying systems change, drawing parallels to `uv` in the Python ecosystem which handles compatibility with careful framing. Users also lamented the lack of support for `.Brewfile` which is written in Ruby.
Speed's Significance
Commenters were divided on whether Homebrew's speed is a significant problem. Some users felt Nanobrew was a "solution looking for a problem," never finding Homebrew's slowness to be a major hindrance. Others strongly disagreed, describing Homebrew updates as "insanely long" and expressing frustration with its auto-update behavior or the time it takes for configuration changes in Nix-Darwin. This highlights that while some prioritize compatibility, others find performance gains a critical quality-of-life improvement, echoing similar debates around faster alternatives like `bun` or `pnpm` in other ecosystems.
Alternative Allusions
The discussion frequently referenced other package managers and ecosystem trends. Many compared Nanobrew to `uv` (a fast Rust-based pip alternative) and `bun` (a fast JavaScript runtime/package manager), noting a general trend towards faster, native-coded replacements for established, slower tools. Other Homebrew alternatives like `zerobrew` were mentioned, along with `MacPorts` as a viable option for users with older macOS versions unsupported by Homebrew. This broader context suggests a desire for modern performance across various development tools.
Legacy Lamentations
A subset of the conversation focused on Homebrew's policy of supporting only the latest three macOS versions. Users with older, but still functional, Macs expressed frustration at being cut off, leading them to seek alternatives like MacPorts or even resort to tools like OpenCore Legacy Patcher to upgrade unsupported hardware. While some argued this policy is reasonable for an open-source project, others felt it was a significant practical barrier.