Live data from Hacker News

Why I'm Leaving NixOS After a Year?

rugu.dev

31–40 of 51 posts

Re: Why I'm Leaving NixOS After a Year?

#31
post #27
post #15

There once was a post "The curse of Nix", or something like that, with the main idea that Nix isn't perfect, but once you tried it, everything else seems even worse. For the first six months of using NixOS I couldn't run anything but a browser (I'm exaggerating a bit), yet all attempts to get back to Arch failed for me. Now it's been over 4 years of having NixOS on all my computers, from Laptops to ARM SoCs driving m…

which nas did you pick?

Some recent Asustor model with 2×3.5" bays and 4×nvme slots.

Probably 6702, but can't verify right now.

Re: Why I'm Leaving NixOS After a Year?

#32
post #16

Earlier quoted context omitted.

Yeah, for all the blog posts about quitting NixOS there's plenty of us who continue using it. I don't think it's just the steep learning curve though, I think it's just not for everyone. You _have_ to enjoy side quests where you dive deep into hairy problems, and effectively be willing to front load effort into setting up an environment so that it works well for you in the long term.

I think OP sums it up pretty well. If there isn't an existing module or one that does exactly what you want, your only way forward is to program your way out of it. That's just not something I want from my daily driver of a distribution. It doesn't help that this programming happens in a weird (to me) functional language.

I think that's fair. The stuff that works for other distros won't work for Nix. However I think eventually everything will be nix-ified. Right now for services there's also an easy escape hatch with docker and oci-containers. It's also what I use if I can't be bothered to nixify some server I want to run.

Re: Why I'm Leaving NixOS After a Year?

#33

Earlier quoted context omitted.

What would make it more pleasant?

I'd say adopting JSON/YAML.

Nix has supported JSON derivations for years, e.g. using commands like `nix derivation show` (I have Emacs configured to run that on any `/nix/store/foo.drv` file I open). It still serialises to ATerm on disk, to avoid breaking existing hashes; which I think is reasonable.

If you mean the programming language used to generate those derivations, then I have no idea what that would even look like; some horrific bastardisation like https://github.com/gliese1337/json-lisp ?

PS: I I found that json-lisp project with a quick search for a LISP-like language that used JSON instead of s-expressions. I like how its README says "Due to the excessive cumbersomeness of writing code in JSON, it is expected that most applications of this library will use it for interpreting auto-generated code of some sort, or API calls, or config files.". If we used that to generate Nix derivations, then we'd want a third* language to generate the json-lisp that generates the derivations ;)

Re: Why I'm Leaving NixOS After a Year?

#34
I'm just starting my second attempt at using NixOS last week because suddenly, my SSD failed and I have limited amount of time to configure my second laptop to get to work. This time I don't think that installing Arch will be the best choice to get to the last state of my laptop as fast as possible (I'm using dotfiles management, but not all things can be automated). And I'm ready to try NixOS again.

The only thing that makes me confident this time, is that I can use LLM to help me. There is absolutely no way I could try Nix again without using LLM. The first attempt at using it just makes me anxious because of docs alone.

And what makes me stick using it? Nix-ld. I think embracing impureness and doing things incrementally will help alleviate the vertical learning curve that is Nix.

After all of this learning curve? I finally can see the rainbow that I can only dreamed of in the past.

Re: Why I'm Leaving NixOS After a Year?

#36
post #19

Earlier quoted context omitted.

I'd say adopting JSON/YAML.

I rarely downvote on HN, but when I do, it must be a comment promoting JSON over any other configuration language (sorry) Nix isn't even that arcane. Its documentation simply sucks. Once you grasp the idea, it feels almost great

To be fair,the Nix code in a very simple config probably looks like some weird JSON like derivative to a layman because of how brackets heavy the language is.

I could see someone glancing over a tutorial and thinking "they should just use JSON instead of their own custom data format" without realizing that Nix is a functional programming language.

Re: Why I'm Leaving NixOS After a Year?

#37
post #16

Earlier quoted context omitted.

Yeah, for all the blog posts about quitting NixOS there's plenty of us who continue using it. I don't think it's just the steep learning curve though, I think it's just not for everyone. You _have_ to enjoy side quests where you dive deep into hairy problems, and effectively be willing to front load effort into setting up an environment so that it works well for you in the long term.

I think OP sums it up pretty well. If there isn't an existing module or one that does exactly what you want, your only way forward is to program your way out of it. That's just not something I want from my daily driver of a distribution. It doesn't help that this programming happens in a weird (to me) functional language.

I think it's weird to most people. I've used NixOS on my personal machines for 2 years and Nix lang is easily the worst thing about it. I'm definitely not a huge functional guy but I'm familiar with Lisp/Scheme and F#. Nix feels completely foreign in a way that those languages didn't.

There have definitely been situations where I've just decided to not try out an application because it wasn't in nixpkgs (it's pretty rare for a package to not exist but one prominent example is Zen browser).

Re: Why I'm Leaving NixOS After a Year?

#39
I daily drive NixOS, and while I initially had the same experience I've settled on some workflows that basically allow me to run anything with minimal maintenance.

I think it's a problem that many tutorials and example configs you find online are very verbose and propose complex patterns, when you don't really need that much for it to be useful. There is still a learning curve, but you don't need to write a modularized configuration framework if you just want some machines with synced config and apps.

I've written about my workflow here [1], but haven't published it anywhere yet. Not sure how useful this is to other people.

[1] https://happens.lol/blog/how-to-nixos-insane/

Re: Why I'm Leaving NixOS After a Year?

#40
post #10

I only got started with NixOS a couple of weeks ago and I must agree. I would never consider running Nix on my daily Desktop machine (I'm using Arch BTW). It's more work and hassle than it's worth it. OTOH I just set it up as the base for my new DIY NAS. There it is limited to just the bare minimum of bringing the system up and providing some core services (including Samba). And for this I found Nix' declarative appr…

Can you elaborate on what were the friction points? I migrated from Arch to Nix several years back because I found maintenance to be incredibly easy and it also allows me to test things without fear. Arch and other imperative distros are still superior for some workflows, but you can always run something imperative inside Nix like FHSEnv or DistroBox. Nix is also available in Arch extra, so it's also possible to do t…

For me (recent NixOS user), it's mainly two things:

- for every configuration item in the software I use, I basically need to learn the way to NixOS-configure it (assuming I don't want to raw-configure everything)

- experimentation is onerous (unless there are workflows I don't know), for example: messing with my sway config requires rebuild switches

I'm not bailing (yet?) but the "ergonomics", well, don't feel ergonomic.

Post reply on HN