Discussion of flakes, from 2025 NixOS Community Survey Report

You may be interested in following Looking for setups/blog not using flakes although I’m not sure someone has yet replied with an exact answer for what you are asking.

In particular, if consuming private flake-based inputs is critical for you, then yes the most natural way to consume a flake is to use another flake. There is GitHub - NixOS/flake-compat · GitHub as a shim if non-flakes code really wants to import a flake as a flake.

Alternatively, many repos that package themselves using flakes also have a default.nix, package.nix, module.nix, etc that may serve as a reasonable entry point instead. This is very repo dependent.

In general, I think that if flakes didn’t exist then structuring a default.nix as a function is a natural way for nix to express inputs and outputs. The function args are the inputs, and the output is a single attrset containing all the outputs.

4 Likes