silent_water [she/her]

  • 0 Posts
  • 47 Comments
Joined 3 years ago
cake
Cake day: October 26th, 2021

help-circle

















  • I think one of the issues with nixos learning materials is that they eschew talking about how to write your own packages. but to really understand anything, you have to get your head around writing and modifying packages. in nix, a package is just a build step that can do I/O during particular phases and produces an output to the nix store, so they’re an essential building block for anything that isn’t utterly trivial.

    the other major stumbling block is working out how modules (the things that let you write config for the system) can actually be composed. adding a new module to imports gives you new config params you can set so you can organize your system config in terms of modules and packages to make things work the way you like.

    Nix Pills are the canonical learning material for packages. I don’t know of any good learning material for modules - I learned by working on nixpkgs and another involved project that made extensive use of modules.

    lastly, nix config files are written in the nix language and it’s a bit idiosyncratic. it almost looks and feels like Haskell but it’s slightly different in important ways. there’s no way around learning it if you have multiple systems and want to share config between them.