Hacker News new | ask | show | jobs
by gnu 1606 days ago
NixOS and Guix are nice! Guix folks are doing some wonderful work off late.

I have used NixOS for a while. But for casual desktop GNU/Linux users, it seem like solving a problem that doesn't exist. Have been using Debian on all my computers since 1998. Unless you are using Debian unstable and updating it daily, I hardly hit any breakage.

Servers and deployments is another story.

3 comments

The magic sauce for desktop users is home-manager, which allows declarative setup of your user environment. And rollbacks to previous generations with one command , in the OS or the boot screen.

I use it to set up my window manager, fonts, Vim/VS Code/Firefox plugins, configure all my tools, set up user-specific systemd jobs, ...

I recently got a new laptop and I had my perfect setup in 20 minutes (install NixOS, git clone config repo, add new machine specific config (disks), apply NixOS config).

I appreciate that it's not for everyone , but it is brilliant.

I also forgot to add one thing that tripped me recently but I am sure a solution exists for it that I am not aware of.

In Debian we do: apt-cache search <search string>

It gives quick results.

The equivalent in nix is (correct me if I am wrong, it has been a while since I did this): nix-env -qaP <search string>

This command takes so long to execute. On a tiny VPS, when I did this, it ran out of memory. I wish things like this are improved.

How does Guix compare to Nix? It seems like by using a scheme-based DSL instead of an ad-hoc configuration language, it solves one of the main complaints the author has about Nix.
IMO Guix is better but still has some work. My major pet-peeve of Guix is it's anti-proprietary software, which is a necessary compromise. The world is composed of many different people and beliefs; software should be belief-agnostic.
I think it's worth pointing out that guix will not package proprietary or binary software in the main channels but nonguix exists for those needs if one absolutely needs to have those packages in guix. At the same time guix packages flatpak which allows one to install most, if not all, of the proprietary packages they may want to use. I think the compromise from the guix maintainers is to develop and distribute free software but at the same time being silent on how a user goes about adding proprietary packages to their system. Which is fair IMO.
Guix is cool but has two big drawbacks:

The major one: package ecosystem. Nix has the largest and most up to date package repo of any distro [1]).

Nix is already somewhat niche, but the Guix community is tiny.

They also have a hard stance against proprietary software, so many things that are packaged for Nix aren't for Guix.

Second: it's pretty slow. A lot of the Nix functionality is implemented in C++ . Guix is all written in Scheme, and uses a rather slow implementation.

The main advantage is more coherent tooling and documentation. (Guix is much younger and doesn't have decades of legacy cruft)

[1] https://repology.org/repositories/statistics

> its pretty slow

Would love to see benchmarks of this if you have them.