Fall County

My First Impressions with NixOS

Or how I found the goddess

So far I've been using NixOS for a couple of days, and I've got some opinions on it! They're mostly good, if not all good. Tl;dr it's a solid 7/10 for now, with the other 3 points reserved for once I've used it more, but I do trust that it'll earn those points enough that I've moved both of my PCs to it.

Up front I do want to say I'm going to be commenting from the perspective of a user, not from the perspective of someone who cares about all of the tech features, because I don't. Immutability? A: It's not here, B: I don't care. Declaritive vs imperitive? Don't know, nor care the difference.

Also note: This is going to be a lot of rambling. I'm getting over bronchitis, and the antibiotics have me a bit loopy. Plus I just wanted to get some initial thoughts out there. I'll likely do a more succinct beginner's guide to NixOS that'll take you through a lot of the basics of just starting this later on, and maybe do a full post-install guide for youtube.

Definitions

"Answer": The thing that needs to happen to fix the problem "Solution": How to implement the answer in a specific environment ".nix": The file /etc/nixos/configuration.nix

What I want from this OS

What I do care about? The fact that I can see what's installed in one place without having to run a command and parse every single package and library I have installed. That alone is what made me want to make the switch. Yes I know that's what makes it declaritive, but the terms are kind of whatever from a review standpoint. It works really well from that perspective.

One of the selling points made by No Boiler Plate was the fact that there are only 2 config files by default, but I'm running up against the fact that it kinda sucks scrolling through that file every time without things like org mode to collapse headings. I likely will end up turning my .nix file into an org mode file for that reason. However, the other thing that can help with that is the fact that you can decide how many config files you have, and how they're split up, which is much more valuable to me.

With that I can have all of my packages declared in one file, and do the rest of it in another, since most of the time when I edit the config it's to change packages around for something or another, and having quick access to that instead of scrolling through 2/3 of a config file is great.

New Game +

Now, besides that I was talking to Andrew on fedi, and in one post about Nix he'd mentioned that one of the things keeping this from casual use is the lack of a store, GUI config tools, and the documentation. The documentation is absolute ass on this OS, which is a shame because it is great. The docs being bad isn't usually a big deal because, y'know, the Arch Wiki is right there and it applies to any Linux distro if you know how to read it, but with Nix that's... not so true.

A lot of the Arch Wiki won't apply to you. A lot of the solutions other people have found to problems won't apply to you. This system isn't FHS compliant, which causes its own issues that you may well be the first person to have. And because of that part alone I'll say that this one isn't for people who don't like tinkering with their system. Arch definitely requires a lot of it, and if you've used arch for any amount of time the experience will help, but indirectly. With Arch there's a lot of research figuring out what terms to type in to get the answer, because someone's figured it out for you. With Nix you have to know the answer to find the solution. If I didn't know that I needed to search for "Where is /usr/share" I wouldn't have found out that it's actually stored somewhere else in Nix.

As for fixing it, you can definitely make it easier for people who would want to do more tinkering with their system, but don't know how, but that takes time, and people who know how to write things in a way that makes the solution easier to find without already knowing the answer. For GUI tools, I'm sure someone could make something that would allow for a GUI to edit the config file, especially since a lot of it is just true/false variables. For a software store that might be a little more difficult to implement, as all of the current tools run [package manager] [install/remove] [package] rather than Nix, which has you add a package name to a file. Nix-env changes that, but that's not why I'm here.

As for actually using it, it's been fine! I've had a couple hiccups along the way (notably with adding PATH variables, and enabling xdg_desktop_portal), however there are a couple of stumbling blocks that I've hit. Notably when to enable software vs when to just install it. For example, xdg_desktop_portal won't do anything if you install it in environment.systemPackages, so you have to specifically enable it with this:

xdg.portal.enable = true; xdg.portal.extraPortals = true;

Which is fine, it's just different to how it otherwise works. But that's expected given that XDP is a piece of software that serves a different function to, say, Steam. However I've found this line in my config file:

programs.steam.enable = true;

Because otherwise steam would crash on startup. I'm pretty sure you can install any software that way, but the easier way just... doesn't seem to work with steam. Good to know that option's there in case another piece of software doesn't work the normal way for some reason.

Now, onto the more fun one: Neofetch.

Look. I'm a basic bitch when it comes to linux, and I want the pretty snowflake in my terminal when I open it. I know it makes my terminal marginally slower, and I could not conceivably give less of a fuck. I want it.

It took me the better part of an hour trying to figure out how to do it in Nix, since .bashrc is configuration.nix now. Also I just couldn't find a lot on how to add a PATH variable to the .nix file. The solution? Use a .bashrc file. It still loads fine, it's just not the default. If anyone knows, get in touch so I can note the solution down! As of right now a lot of answers are everywhere from the NixOS wiki, to the Hyprland reddit, and having this centralized somewhere will help. Even if you just add it to the wiki, point me to it, because I wanna know regardless.

Funny moments along the way

This has nothing to do with Nix, but whatever. I decided to try Hyprland out of curiosity. I installed it, then typed Hyprland into my terminal, and then proceeded to cackle when I saw that the default system background was the Hyprland OS-tan Hyprchan.

Like, maybe don't do that for software that people use at work. Still hilarious, but it's hilarious for that reason.

Conclusions

And what she did to me when I found her

I do like what I see, though I also understand that I like this specifically because of my time with vanilla Arch. If I didn't want to spend a full day tinkering with my system just to get stuff up and running I would have absolutely switched back to anything else, but that's not a bad thing. There should be more user-centric options available where you do choose every piece of software that goes into your system from the ground up. There should be technological tinker-toys for people who want to play with them.

I will say, though, I do think that once the documentation is better this will be a bit easier to handle than Arch, at least for me and my brain. Compared to how long it took me to get my Arch system usable for the first time, this has been a cakewalk. It took me days to get OBS working on Arch, while on Nix it took... a couple of hours. And on the Arch install it still didn't work as intended. However, I have a feeling that I now know why it didn't work on Arch, and if I don't end up sticking to Nix at least now I'll know how to find the solution.


Recent posts