29 | He/Him | Garlic Bread Enjoyer | Software Engineer

  • 0 Posts
  • 94 Comments
Joined 2 years ago
cake
Cake day: June 22nd, 2023

help-circle

  • Just to clarify for everyone else:

    • Nixpkgs is the equivalent of a core distro repository for NixOS. Instead of Core + Extra + Multilib + AUR on Arch, we just have Nixpkgs that has everything
    • A Nix “module” is essentially an app with pre-packaged declarable options. So rather than just installing something as is, you can use its options to declare how you want it installed. I can get firefox, with a package definition for firefox-nightly, and also tell it which addons I want bundled, for example. 99% of the time, this is the preferred way to do things.
    • Home-Manager is a third-party Nix module, that lets you declare stuff in ~/. Very convenient for shells, browsers, and whatever else you want in there. Let’s say you want to have a specific shell, with a specific ssh signing key, and whatever prompt you like. The home-manager daemon would build it for you with a new system evaluation.
    • Stylix is another third-party Nix module. For supported things, it will style your apps with the preferences you’ve defined. Handy if you want a uniform look and feel for the things you use




  • This is a good example of what people consistently overlook/misunderstand, when it comes to Nix.

    Obviously you can remount a /home, or just pull the dotfiles from a personal repo, but the strength of Nix is also in that I can re-create my entire config exactly how it is defined. If i were to setup a machine completely from scratch, with a mature enough config, it will get me from 0 to my exact desktop completely unattended.

    But there are also many more advantages to it, at least in my eyes. Let’s take trying/tweaking new packages as an example. Yesterday I pulled an old repo for an Outer Wilds mod. The thing needs a dev environment, and a mod manager for the actual game. A nix shell got me both, I finished my work, and when I exit out of fish, both are gone, just as I wanted them to be.

    Another good example would be partial os updates. I’ve used Arch for almost 9 years before switching to Nix, and pretty much a top3 Arch rule is not doing partial updates, or partial rollbacks. In case of a breakage, I would have to manually redownload an older version of a tarball, pacman -U the package, and then hope i’m not cooked. In the case of gcc incompatibilities, it can quickly become a massive pain in the ass. My nix flake would never experience this problem, because I already have two different scenarios available - either i build based on an older lockfile from my git repo, or I create an overlay for a specific input I need, so that it still pulls what it needs, and doesn’t interfere with the rest of my system







  • Correct. Atomic distros don’t apply the update, unless it is ready to be applied successfully all together, usually with an option to restore the previous state, without the need of something like btrfs snapshots.

    With Nix(-OS) as an example - your bootloader entry is just a reference a giant list of what you need to get out of the Nix store, to achieve the config you want. Many of those can coexist in the same system as a result, including different versions of the same package

    This setup won’t really teach you anything different in relation to containers though.




  • I am tired of the boomer narrative of that it’s always those “young people” ruining everything. Oldest millennials are now in their mid-40’s. Or even worse, the youngest gen-z people are almost 18 now. These people have been paying their taxes for years on end now.

    The only terrified people in this scenario are the literal parasites who don’t pay anything, through loopholes and theft

    The lone defender of the billionaires at this point says everything we need to know