This commit is contained in:
mjallen18
2025-07-21 18:59:53 -05:00
parent b43816579f
commit e3bfbae131
28 changed files with 342 additions and 3383 deletions

View File

@@ -64,7 +64,7 @@ in
hyprland = {
enable = true;
xwayland.enable = true;
portalPackage = pkgs.xdg-desktop-portal-hyprland;
portalPackage = lib.mkDefault pkgs.xdg-desktop-portal-hyprland;
};
nm-applet.enable = true;
@@ -161,7 +161,7 @@ in
enable = true;
wlr.enable = true;
xdgOpenUsePortal = true;
extraPortals = [
extraPortals = lib.mkDefault [
pkgs.xdg-desktop-portal-hyprland
pkgs.xdg-desktop-portal-gnome
pkgs.xdg-desktop-portal-gtk

View File

@@ -1,6 +1,6 @@
{ lib, system, ... }:
let
isArm = builtins.match "aarch64*" system != null;
isArm = "aarch64-linux" == system;
in
{
hardware = {

View File

@@ -53,8 +53,8 @@
# Add any other external HM modules here
];
# users.${config.${namespace}.user.name} = lib.types.mkAliasDefinitions options.${namespace}.home.extraOptions;
users.admin = lib.mkAliasDefinitions options.${namespace}.home.extraOptions;
users.${config.${namespace}.user.name} = lib.mkAliasDefinitions options.${namespace}.home.extraOptions;
# users.admin = lib.mkAliasDefinitions options.${namespace}.home.extraOptions;
verbose = true;
};

View File

@@ -0,0 +1,66 @@
{
config,
lib,
pkgs,
namespace,
...
}:
with lib;
let
cfg = config.${namespace}.user;
in
{
options.${namespace}.user = with types; {
email = lib.mkOption {
type = str;
default = "jalle008@proton.me";
description = "The email of the user.";
};
extraGroups = lib.mkOption {
type = (listOf str);
default = [ ];
description = "Groups for the user to be assigned.";
};
extraOptions = lib.mkOption {
type = attrs;
default = { };
description = "Extra options passed to <option>users.users.<name></option>.";
};
fullName = lib.mkOption {
type = str;
default = "Matt Jallen";
description = "The full name of the user.";
};
name = lib.mkOption {
type = str;
default = "matt";
description = "The name to use for the user account.";
};
};
config = {
users.users.${cfg.name} = {
inherit (cfg) name;
extraGroups = [
"wheel"
"systemd-journal"
"mpd"
"audio"
"video"
"input"
"plugdev"
"lp"
"tss"
"power"
"nix"
] ++ cfg.extraGroups;
group = "users";
home = "/home/${cfg.name}";
isNormalUser = true;
shell = lib.mkDefault pkgs.zsh;
uid = 1000;
} // cfg.extraOptions;
};
}