calling it, multi user is building!!!

This commit is contained in:
Chris Kruining 2025-03-23 21:04:12 +01:00
parent ce69116c39
commit c165dbd9a3
Signed by: chris
SSH key fingerprint: SHA256:nG82MUfuVdRVyCKKWqhY+pCrbz9nbX6uzUns4RKa1Pg
8 changed files with 100 additions and 42 deletions

View file

@ -16,5 +16,16 @@
# EXPERIMENTS # EXPERIMENTS
services.auth.enable = true; services.auth.enable = true;
root = {
user = {
full_name = "__ROOT__";
email = "__ROOT__@${config.networking.hostName}";
};
shell = {
default = "zsh";
};
};
}; };
} }

View file

@ -0,0 +1,50 @@
{ ... }:
{
user = {
full_name = "KAAS";
email = "kaas@kaas.kaas";
is_trusted = false;
};
themes = {
enable = true;
theme = "everforest";
polarity = "dark";
};
develop = {
rust.enable = true;
js.enable = true;
dotnet.enable = true;
};
desktop = {
plasma = {
enable = true;
# autoLogin = true;
};
applications = {
email.enable = true;
};
terminal = {
default = "ghostty";
ghostty.enable = true;
};
editors = {
default = "nvim";
nvim.enable = true;
};
browsers = {
default = "chromium";
chrome.enable = true;
};
};
shell = {
default = "zsh";
};
}

View file

@ -1,10 +1,8 @@
args@{ self, inputs, lib, pkgs, system ? "", config, options, ... }: let args@{ inputs, lib, pkgs, config, options, ... }: let
inherit (lib.my) mapModulesRec'; inherit (lib.my) mapModulesRec';
in in
{ {
imports = [ imports = []
# (import ../modules/home/shell/default.nix (args // { user = "root"; }))
]
++(mapModulesRec' ../modules/home (file: (import file (args // { user = "root"; })))); ++(mapModulesRec' ../modules/home (file: (import file (args // { user = "root"; }))));
config = { config = {

View file

@ -38,7 +38,6 @@ in rec
imports = [ imports = [
inputs.home-manager.nixosModules.home-manager inputs.home-manager.nixosModules.home-manager
"${path}/hardware.nix" "${path}/hardware.nix"
./_root.nix
] ]
++ (mapModulesRec' ../modules/system import); ++ (mapModulesRec' ../modules/system import);
@ -59,15 +58,15 @@ in rec
}) })
(filterAttrs (n: v: !elem n ["system"]) attrs) (filterAttrs (n: v: !elem n ["system"]) attrs)
(import path) (import path)
(args@{ inputs, lib, pkgs, config, options, ... }: {
imports = mapModulesRec' ../modules/home (file: (import file (args // { user = "root"; })));
})
] ]
++ (map (user: { ++ (map (user: (args@{ inputs, lib, pkgs, config, options, ... }: {
_module.args.user = user; imports = mapModulesRec' ../modules/home (file: (import file (args // { inherit user; })));
imports = []
++ (mapModulesRec' ../modules/home (file: file));
modules.${user} = (import "${path}/users/${user}/default.nix" args); modules.${user} = (import "${path}/users/${user}/default.nix" args);
}) users); })) users);
}; };
mapHosts = dir: attrs @ {system ? system, ...}: mapHosts = dir: attrs @ {system ? system, ...}:

View file

@ -32,7 +32,7 @@ in {
(mkIf (cfg.default == "nvim") { (mkIf (cfg.default == "nvim") {
home-manager.users.${user}.home.packages = attrValues { home-manager.users.${user}.home.packages = attrValues {
inherit (pkgs) imagemagick editorconfig-core-c sqlite deno pandoc nuspell; inherit (pkgs) imagemagick editorconfig-core-c sqlite deno pandoc nuspell;
inherit (pkgs.hunspellDicts) en_GB nl_NL; inherit (pkgs.hunspellDicts) nl_NL en_GB-ise;
}; };
}) })
]; ];

View file

@ -43,34 +43,9 @@ in {
# }; # };
stylix = { stylix = {
enable = true;
autoEnable = true;
base16Scheme = "${pkgs.base16-schemes}/share/themes/${cfg.theme}.yaml"; base16Scheme = "${pkgs.base16-schemes}/share/themes/${cfg.theme}.yaml";
image = ./${cfg.theme}.jpg; image = ./${cfg.theme}.jpg;
polarity = cfg.polarity; polarity = cfg.polarity;
fonts = {
serif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Serif";
};
sansSerif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Sans";
};
monospace = {
package = pkgs.nerd-fonts.jetbrains-mono;
name = "JetBrainsMono Nerd Font Mono";
};
emoji = {
package = pkgs.noto-fonts-emoji;
name = "Noto Color Emoji";
};
};
}; };
}; };
} }

View file

@ -1,4 +1,4 @@
{ inputs, config, lib, ... }: { inputs, config, lib, pkgs, ... }:
let let
inherit (lib) mkIf; inherit (lib) mkIf;
inherit (lib.options) mkEnableOption; inherit (lib.options) mkEnableOption;
@ -15,6 +15,35 @@ in
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
stylix = {
enable = true;
autoEnable = true;
# base16Scheme = "${pkgs.base16-schemes}/share/themes/${cfg.theme}.yaml";
# image = ./${cfg.theme}.jpg;
# polarity = cfg.polarity;
fonts = {
serif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Serif";
};
sansSerif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Sans";
};
monospace = {
package = pkgs.nerd-fonts.jetbrains-mono;
name = "JetBrainsMono Nerd Font Mono";
};
emoji = {
package = pkgs.noto-fonts-emoji;
name = "Noto Color Emoji";
};
};
};
}; };
} }

View file

@ -1,4 +0,0 @@
{}:
{
}