flake: start refactoring

This commit is contained in:
Veneficium 2025-02-11 22:00:49 +01:00
parent 4b8923b5f5
commit 8b4e41c968
8 changed files with 62 additions and 76 deletions

View file

@ -1,7 +1,9 @@
{ lib, ... }:
{
imports = [
./locale.nix
./system/boot.nix
./system/nix.nix
./system/locale.nix
./users/fedfer.nix
./users/veneficium.nix
@ -34,6 +36,8 @@
];
settings = {
system.boot.windows.enable = lib.mkDefault false;
users.fedfer.enable = lib.mkDefault false;
users.veneficium.enable = lib.mkDefault false;

View file

@ -0,0 +1,31 @@
{
pkgs,
config,
lib,
...
}:
{
options.settings.system.boot = {
windows.enable = lib.mkEnableOption "Enable windows dual boot";
};
config = {
boot.kernelPackages = pkgs.linuxPackages_latest;
boot.loader = {
efi.canTouchEfiVariables = true;
systemd-boot.enable = true;
systemd-boot.edk2-uefi-shell.enable = true;
systemd-boot.configurationLimit = 10;
systemd-boot.editor = false;
systemd-boot.windows = lib.mkIf config.settings.system.boot.windows.enable {
"11" = {
title = "Windows";
efiDeviceHandle = "FS0";
};
};
};
};
}

View file

@ -0,0 +1,9 @@
{ ... }:
{
nix.settings.experimental-features = [
"nix-command"
"flakes"
];
nixpkgs.config.allowUnfree = true;
}