One Nix flake to rule them all: 12,000 flakes in a single input

One Nix flake to rule them all: 12,000 flakes in a single input

A Nix developer grew tired of adding flake inputs one by one, each dragging in its own nixpkgs. So he built omniflake, a single flake that carries nearly 12,000 other flakes behind one input, accessible lazily. The trick: instead of declaring thousands of inputs, omniflake stores pins in a JSONL index and fetches only what you ask for. He also fixed a quadratic slowdown in Nix's lock file generation, making the megaflake practical.

I love the idea of federation but I want the simplicity of centralization. As Nix users, I want my cake and I want to eat it too: omniflake is my cake.
  1. wredcoll

    When I first met NixOS, it struck me as a super cool idea that would be incredibly useful as soon as every other piece of software/programmer in the world converted to using it.

    I haven't seen anything to change my mind since.

  2. jchw

    I'm not entirely sure if it's a good idea per se, but hell, what's the point in making everything properly lazy if you couldn't. I mean me personally, I routinely use 20-30 flake inputs for large system configurations and I've never really minded this at all. The only real concern I have is that overriding Nixpkgs to avoid duplicates can occasionally break since the dependency may not be ready for the latest Nixpkgs, but this so far has only ever hit me with nix-vim, which arguably should be in Nixpkgs anyways in some form (although I haven't used it in a while so not sure what the status is.)

    Because you have to, I searched and found that at least one of my flakes are in there, nix-binary-ninja, which is a Nix flake for the proprietary Binary Ninja disassembler/decompiler. Neat. (FYI though, while I use that, I'm not sure I actually recommend it; it does gross things to make binja use system libraries for better integration, which right now breaks some extensions. Oh well...)

  3. AyanamiKaine

    Wow, it looks really cool!

    I will definitely try it! If there is one think that breaks me is always chasing that one shared library for example when developing something using SDl3 and its GPU API.

More from this day

2026-08-30