Skip to content

Fix issue #5: Refactor default.nix into modular files#14

Open
MattiasKockum wants to merge 5 commits into
cloud-gouv:mainfrom
MattiasKockum:refactor/split-default-nix
Open

Fix issue #5: Refactor default.nix into modular files#14
MattiasKockum wants to merge 5 commits into
cloud-gouv:mainfrom
MattiasKockum:refactor/split-default-nix

Conversation

@MattiasKockum

@MattiasKockum MattiasKockum commented Apr 22, 2026

Copy link
Copy Markdown

Fixes #5

What changed?

  • Split default.nix into:
    installers/default.nix
    installers/netboot.nix
    installers/usb.nix
    registry/default.nix
    dev/ci.nix
    dev/default.nix
    dev/shell.nix
    lib/default-system.nix
  • Improved readability and maintainability

Motivation

This refactor prepares the ground for working on features without cluttering default.nix.

How to test?

  • nix-instantiate -A usb-installer produces the same hash. Same goes for 'toplevelRegistry'.
  • nix-instantiate -A net-installer produces the same error before and after (that could lead to the oppening of a separate issue)
  • nix-instantiate -A shell produces a different hash but this is because ci uses src = ../. so any change in the code base actually changes the hash here.

Split USB and netboot installers into a new 'installers' directory.
Add myself as a contributor.
Move 'terminals' and 'toplevelRegistry' into a new 'registry' directory.
Move ci code and shell into 'dev' directory.
Move defaultSystem into 'lib' directory.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Split default.nix in modules

1 participant