Skip to content

Nilla

Nilla is a simple-to-use, easy-to-extend Nix framework for managing projects.

Why Nilla?

Nilla combines many of the lessons learned from working with Flakes, NixOS Modules, and Legacy default.nix files. Bringing the best qualities of these different strategies together in a modular fashion allows for much easier management of projects than before. Nilla gives you the schema guarantees of Flakes, but with the ability to extend or change that schema as you need. You get the type-checking and pluggability of NixOS Modules without a forced Nixpkgs import while also benefiting from some features like Portable Submodules. Finally, you have the ability to manage more than one system, package, shell, etc. easily, unlike with legacy default.nix and shell.nix approaches.

Features

Nilla is ready to use out of the box with no additional configuration or Nix settings required.

FeatureNillaFlakesLegacy
Pinnable inputs✔️✔️
Input loaders✔️
Minimal boilerplate✔️✔️
Configurable inputs✔️⚠️*
Extensible✔️
Lazy✔️⚠️**✔️
Available OOTB✔️✔️
Nixpkgs-agnostic✔️✔️
Type checked✔️
Configurable systems✔️
Defined schema✔️✔️
Stable⚠️***⚠️****✔️

⚠️* Legacy configuration using default.nix and shell.nix can only accept dynamic values via function attributes during instantiation, dramatically limiting what can be modified by consumers of a project.

⚠️** Flakes have a work-in-progress feature “Lazy Trees” which hopes to address its input laziness shortcoming. However, this feature is not yet available.

⚠️*** Nilla isn’t stable… yet! We are moving towards a 1.0.0 stability guarantee, but for now it is expected that some things will be broken or change as development continues on pre-1.0 versions.

⚠️**** Flakes are widely used but remain an experimental feature of Nix subject to change.

Projects using Nilla