NixOS: The journey continues (part 2)

Since part 1, I have done work to configure and make configurable the GUI for my budding NixOS setup. If you're interested in the code, the PR for it can be found here. Comments and feedback welcome!

Now, getting into some detail, AI, specifically Codex, has been really valuable thus far with this project. It's been a useful collaborator in discovering config options, understanding how they work (standalone or with others), figuring out best practices, and reviewing my work. One particularly interesting application has been using GitHub Copilot to search for real-world examples of derivations that I could draw inspiration from. I mainly did this to help with writing derivations for things not available in Nixpkgs; these can be found in the pkgs directory.

It turns out that there are different strategies for writing a derivation depending on the kind of software you're looking to package. So far, I've got one for a binary program, a Go program, and a Python program. None of them look like the others. Codex was useful in ensuring I was on the right track and in offering suggestions.

Generally, being able to prompt Codex with "could you take a look at this, am I on the right track?", or "is this the best way to do this?" took a lot of frustration out of things. I think having these kinds of interactions is a great way to learn and get ramped up quickly because you aren't just letting the AI do all the work; you're pair programming with it. I, for one, believe this approach has helped me get up to speed at a much faster pace than I would have otherwise. I'm still fuzzy on a couple of things, like inherit for instance, but I have come away with a better understanding of and greater appreciation for the configurability and level of control Nix offers.

The work behind the PR also taught me a few things:

From here, I plan on creating modules for integrating with NVIDIA GPUs, AMD hardware (CPU & GPU), and Intel. I think that will be the last major piece before I start testing this in my VM. Let's see how it goes. Till next time!

Part 3