Check it out: https://blog.xvrqt.com/nix-defaults.html
#nix #nixos #rust #flakes #programming #coder #hacking #crows
@crow there is the short mkEnableOption which is usually used for whatever.enable, doesn't save much but I find it somewhat convenient
One thing I don't understand about your code is wgqt.machines' default value, where is "defaults" coming from? I'd have expected something like "{}"
@crow no problem.
I can't comment on how understandable your guide is because I've already written modules before (yes, even with type attrsOf submodule...)
Also, something I just spotted: you're using "with lib;" which is an antipattern: https://nix.dev/guides/best-practices#with-scopes rather inherit from lib.
What I do like is that your options live in a separate flake. I wrote a blog post about that as well.
Anyhow, nice to see a practical example, I think most people tend not to use options.