NixOS-Configuration/common/users/cameron/default.nix

38 lines
820 B
Nix
Raw Normal View History

{ config, lib, pkgs, ... }:
with lib; let
cfg = config.user.cameron;
in {
options.user.cameron = {
enable = mkEnableOption "user cameron";
2024-01-10 00:41:10 +00:00
};
config = mkIf cfg.enable {
users = {
groups.cameron.gid = 1000;
users.cameron = {
description = "Cameron";
isNormalUser = true;
uid = 1000;
group = "cameron";
2024-01-10 00:41:10 +00:00
extraGroups = [ "wheel" ] ++
(lib.optionals config.networking.networkmanager.enable [ "networkmanager" ]);
home = "/home/cameron-nix";
createHome = true;
shell = pkgs.zsh;
packages = (with pkgs; [
direnv
nix-direnv
2024-01-11 21:14:59 +00:00
] ++ (lib.optionals ((builtins.length config.desktop) != 0) [
bibata-cursors
bibata-cursors-translucent
]));
};
};
};
}