snowfall lib migration WIP

This commit is contained in:
Aleksandr Lebedev 2025-08-06 12:18:08 +02:00
parent dc2440015e
commit b9dadac2af
31 changed files with 9106 additions and 382 deletions

21
templates/default.nix Normal file
View file

@ -0,0 +1,21 @@
{...}: {
#lib = {
# path = ./lib;
#};
module = {
path = ./module;
description = "Snowfall module";
};
overlay = {
path = ./overlay;
description = "Snowfall overlay";
};
system = {
path = ./system;
description = "Snowfall system(host)";
};
home = {
path = ./home;
description = "Snowfall home";
};
}

View file

@ -0,0 +1,23 @@
{
lib,
pkgs,
config,
...
}:
# User information gathered by Snowfall Lib is available.
let
name = config.snowfallorg.user.name;
home = config.snowfallorg.user.home.directory;
in {
home = {
packages = with pkgs; [
librewolf
];
sessionVariables = {
EDITOR = "emacsclient -c";
};
stateVersion = "25.05";
};
}

View file

@ -0,0 +1,25 @@
{
lib,
pkgs,
inputs,
namespace,
system,
target,
format,
virtual,
systems,
config,
...
}:
with lib;
with lib.${namespace}; let
cfg = config.${namespace}.module;
in {
options.${namespace}.module = with types; {
enable = mkBoolOpt false "Enable module";
};
config =
mkIf cfg.enable {
};
}

View file

@ -0,0 +1,3 @@
_: (final: prev: {
package = prev.package.override {};
})

View file

@ -0,0 +1,39 @@
{
lib,
pkgs,
inputs,
namespace,
system,
target,
format,
virtual,
systems,
config,
...
}: {
imports = [./hardware-configuration.nix];
# Enable Bootloader (EFI or BIOS)
#system.boot.efi.enable = true;
#system.boot.bios.enable = true;
# Better battery life on laptops
# system.battery.enable = true;
# suites.desktop.enable = true;
# suites.development.enable = true;
# suites.server.enable = true;
# Nvidia Drivers
# hardware.nvidia.enable = true;
# Add packages (custom for ones in these dotfiles)
# environment.systemPackages = with pkgs; [
# ${namespace}.package
# ];
# ======================== DO NOT CHANGE THIS ========================
system.stateVersion = "25.05";
# ======================== DO NOT CHANGE THIS ========================
}