refactor: start making flake exposed modules with desktop

This commit is contained in:
matt1432 2024-06-27 00:56:27 -04:00
parent c119757766
commit 85a3c28438
49 changed files with 208 additions and 128 deletions

View file

@ -1,4 +1,8 @@
{config, ...}: let
{
config,
self,
...
}: let
inherit (config.vars) mainUser hostName;
in {
imports = [
@ -7,7 +11,6 @@ in {
../../modules/android.nix
../../modules/ags
../../modules/audio.nix
../../modules/hyprland
../../modules/kmscon.nix
../../modules/printer.nix
../../modules/ratbag-mice.nix
@ -16,14 +19,22 @@ in {
./modules/gpu-replay.nix
./modules/nix-gaming.nix
self.nixosModules.desktop
];
vars = {
mainUser = "matt";
hostName = "binto";
promptMainColor = "purple";
};
roles.desktop = {
user = config.vars.mainUser;
mainMonitor = "desc:GIGA-BYTE TECHNOLOGY CO. LTD. G27QC 0x00000B1D";
greetdDupe = false;
displayManager.duplicateScreen = false;
fontSize = 12.5;
};

View file

@ -1,10 +1,19 @@
{
config,
modulesPath,
self,
...
}: {
nixpkgs.hostPlatform = "x86_64-linux";
imports = [(modulesPath + "/installer/scan/not-detected.nix")];
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
self.nixosModules.nvidia
];
nvidia = {
enable = true;
enableCUDA = true;
};
boot = {
kernelModules = ["kvm-intel"];
@ -45,9 +54,4 @@
zramSwap.enable = true;
hardware.cpu.intel.updateMicrocode = config.hardware.enableRedistributableFirmware;
nvidia = {
enable = true;
enableCUDA = true;
};
}

View file

@ -1,4 +1,8 @@
{config, ...}: let
{
config,
self,
...
}: let
inherit (config.vars) mainUser hostName;
in {
imports = [
@ -7,21 +11,30 @@ in {
../../modules/android.nix
../../modules/ags
../../modules/audio.nix
../../modules/hyprland
../../modules/kmscon.nix
../../modules/plymouth.nix
../../modules/printer.nix
../../modules/tailscale.nix
./modules/security.nix
self.nixosModules.desktop
];
vars = {
mainUser = "matt";
hostName = "wim";
promptMainColor = "purple";
fontSize = 12.5;
};
roles.desktop = {
user = config.vars.mainUser;
mainMonitor = "eDP-1";
isLaptop = true;
isTouchscreen = true;
fontSize = 12.5;
};
users.users.${mainUser} = {