• 0 Posts
  • 3 Comments
Joined 2 months ago
cake
Cake day: August 6th, 2025

help-circle
  • I have been using Nix for a year now, and I am not looking back.

    All regular package managers have a problem: Sometimes a system won’t work if a specific combination of packages is installed. To prevent this, package managers block those combinations. However, how does the package manager know which combination would break the system? It is tested beforehand, and a list of illegal combinations is maintained. However, this comes with a problem: How do you test every combination of packages? If a package manager tracks just 1000 packages, there are 2^1000 possible combinations to evaluate. This means that when a package manager becomes more popular, and more packages get added, relatively fewer combinations get tested, therefore increasing the chance someone breaks his system by installing a unique combination of packages, that wasn’t evaluated and apparently breaks the system. In other words: Package managers have a flaw that causes your system to break if the package manager becomes too popular. The common solution is to create a new package manager from scratch that does exactly the same thing as the old one, but isn’t popular yet, and therefore works. However, since it works, it becomes more popular, causing it to no longer work.

    Nix is different. It is designed from the bottom up that every combination of packages is possible. It is impossible that one package breaks another. This creates some other advantages as well: there is no evaluation to see whether packages break other packages, allowing maintainers to add more packages to the repository. The result: even though it is not even close to the most used package manager, it is the one with the most packages in its repository.

    Yes, there are problems. The biggest is that there is no easy mode yet. But that can be implemented later. For now I see Nix (or something similar like Guix) to be the future of package managers.