mirror of
https://github.com/Superredstone/nixos.git
synced 2026-03-07 12:28:02 +01:00
feat: modular zram
This commit is contained in:
@@ -57,6 +57,7 @@
|
||||
gamingSystem = true;
|
||||
# Currently supported: plasma, gnome, hyprland and none
|
||||
desktopEnvironment = "gnome";
|
||||
enableZram = true;
|
||||
additionalModules = [
|
||||
];
|
||||
};
|
||||
@@ -66,12 +67,14 @@
|
||||
email = personalEmail;
|
||||
workSystem = true;
|
||||
desktopEnvironment = "gnome";
|
||||
enableZram = true;
|
||||
};
|
||||
nixosConfigurations."bomba" = mkSystem "bomba" {
|
||||
system = "x86_64-linux";
|
||||
email = personalEmail;
|
||||
user = username;
|
||||
desktopEnvironment = "none";
|
||||
enableZram = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ name:
|
||||
gamingSystem ? false,
|
||||
workSystem ? false,
|
||||
desktopEnvironment ? "",
|
||||
enableZram ? false,
|
||||
additionalModules ? [ ],
|
||||
}:
|
||||
let
|
||||
@@ -36,6 +37,7 @@ let
|
||||
currentSystemDe = desktopEnvironment;
|
||||
gamingSystem = gamingSystem;
|
||||
workSystem = workSystem;
|
||||
enableZram = enableZram;
|
||||
nixvim = nixvim;
|
||||
millennium = millennium;
|
||||
nur = nur;
|
||||
|
||||
@@ -48,6 +48,4 @@
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
|
||||
zramSwap.enable = true;
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./hardware.nix
|
||||
./keyboard.nix
|
||||
./security.nix
|
||||
./services.nix
|
||||
|
||||
4
modules/nix-config/hardware.nix
Normal file
4
modules/nix-config/hardware.nix
Normal file
@@ -0,0 +1,4 @@
|
||||
{ enableZram, ... }:
|
||||
{
|
||||
zramSwap.enable = enableZram;
|
||||
}
|
||||
Reference in New Issue
Block a user