diff --git a/hosts/nom/fs.nix b/hosts/nom/fs.nix index a7e1af6..66e2de1 100644 --- a/hosts/nom/fs.nix +++ b/hosts/nom/fs.nix @@ -1,4 +1,4 @@ -{config, ...}: { +{ fileSystems = { "/" = { device = "rpool/root/nixos"; diff --git a/modules/zfs.nix b/modules/zfs.nix index 63180e8..c1dda8a 100644 --- a/modules/zfs.nix +++ b/modules/zfs.nix @@ -1,4 +1,8 @@ -{pkgs, ...}: { +{ + pkgs, + config, + ... +}: { boot.supportedFilesystems = ["zfs"]; boot.kernelPackages = config.boot.zfs.package.latestCompatibleLinuxPackages; diff --git a/users/myuser/core/default.nix b/users/myuser/core/default.nix index 3d8c203..4029100 100644 --- a/users/myuser/core/default.nix +++ b/users/myuser/core/default.nix @@ -20,7 +20,6 @@ packages = with pkgs; [ bandwhich btop - colorcheck fd kalker neofetch diff --git a/users/myuser/default.nix b/users/myuser/default.nix index 43e0f7a..4f70da5 100644 --- a/users/myuser/default.nix +++ b/users/myuser/default.nix @@ -22,6 +22,7 @@ with lib; { #impermanence.home-manager.impermanence ./core ./dev + ./modules #] #++ optionals config.programs.sway.enable [ # ./graphical diff --git a/users/myuser/dev/default.nix b/users/myuser/dev/default.nix index 6627584..2d501fd 100644 --- a/users/myuser/dev/default.nix +++ b/users/myuser/dev/default.nix @@ -1,8 +1,4 @@ -{ - lib, - pkgs, - ... -}: { +{pkgs, ...}: { home = { extraOutputsToInstall = ["doc" "devdoc"]; file.gdbinit = { diff --git a/users/myuser/modules/default.nix b/users/myuser/modules/default.nix new file mode 100644 index 0000000..db4ab03 --- /dev/null +++ b/users/myuser/modules/default.nix @@ -0,0 +1,5 @@ +{ + imports = [ + ./uid.nix + ]; +} diff --git a/users/myuser/modules/uid.nix b/users/myuser/modules/uid.nix new file mode 100644 index 0000000..4bd9697 --- /dev/null +++ b/users/myuser/modules/uid.nix @@ -0,0 +1,22 @@ +{ + config, + lib, + ... +}: +with lib; { + options = { + home.uid = mkOption { + type = types.int; + example = 1000; + description = "The user's uid."; + }; + }; + config = { + assertions = [ + { + assertion = config.home.uid != ""; + message = "UID could not be determined"; + } + ]; + }; +}