Ixnay is a Nix shell wrapper that I'm writing as I learn about Nix and how to do various operations.
I did this because Nix (as of 6/2022) still seems to be in a contentious transition/rewrite period where sometimes the acceptable way to do something is via a nix-*
command and sometimes it is a nix <whatever>
command. And the docs out there often differ on this too. I also keep hearing rumors about the nix command not being fully stable yet and that people still use the old commands for things, and that there's some kind of tension between the "old devs" and the "new devs". So since both are currently supported (I think?), I'm skirting around all this nonsense by writing a unified TUI that will allow me to change the underlying implementation when the time is right for some given operation, without messing up my muscle memory, and hopefully adding some ease-of-use.
It's a WIP and will probably change a lot so I don't recommend it yet. The goal is to not have to use this anymore and just rely on the nix
command at some point in the future, once that is broadly regarded as stable and complete (and assuming it has a nice TUI, for my personal definition of "nice").
I based it off pac
, my pacman
wrapper. Things both do that I think are nice: It outputs the actual underlying command it is running, in yellow, to STDERR. It outputs help if you pass no (or a non-understood) argument.
Also, related, I think Guix
is a much better-designed project from the ground up, and I like that it uses Guile/Scheme/Lisp for its config language for everything from the bootloader point onward instead of this very niche language that Nix uses, but Nix is currently much better supported and has a far greater library of stuff, and I don't have as much time to tinker as I would prefer currently, so Nix it is. Also, the emphasis on free software in Guix is admirable, but often an obstacle, and I don't like obstacles. I wish a Nix-like OS existed that just used, like, an enforced subset of Bash to work (similar to what Docker does), perhaps coupled with a Bash function library; it would be significantly more accessible IMHO since Bash is just ubiquitous. (Bash also lamely uses linked lists for arrays and dicts, but I digress. "There are no solutions, only compromises." Whether you agree or not, nix-lang is in the way of Nix adoption, IMHO.)