flake-parts.flakeModules

Adds the flakeModules attribute and flakeModule alias.

This module makes deduplication and disabledModules work, even if the definitions are inline modules or importApply.

Installation

To use these options, add inside the mkFlake:

imports = [
  inputs.flake-parts.flakeModules.easyOverlay
];

Run nix flake lock and you're set.

Options

flake

flake.flakeModule

flake.flakeModules

flake

Raw flake output attributes. Any attribute can be set here, but some attributes are represented by options, to provide appropriate configuration merging.

Type: lazy attribute set of raw value

Declared by:

flake-parts

flake.flakeModule

Alias of flakeModules.default.

Type: submodule

Declared by:

flake-parts

flake.flakeModules

flake-parts modules for use by other flakes.

If the flake defines only one module, it should be flakeModules.default.

You can not read this option in defining the flakeā€™s own imports. Instead, you can put the module in question into its own file or let binding and reference it both in imports and export it with this option.

See Dogfood a Reusable Module for details and an example.

Type: lazy attribute set of module

Default: { }

Declared by:

flake-parts