Migrate config from dotfiles

This commit is contained in:
2023-06-26 14:40:59 +01:00
parent e45609ea4b
commit a7e1525e34
69 changed files with 2236 additions and 161 deletions

View File

@ -15,6 +15,8 @@ with lib.my;
services = mkOpt' attrs { } "Services managed directly from home-manager";
};
dconf.settings = mkOpt' attrs { } "dconf settings to enable";
env = mkOption {
type = attrsOf (oneOf [ str path (listOf (either str path)) ]);
apply = mapAttrs (n: v:
@ -37,11 +39,14 @@ with lib.my;
extraGroups = [ "networkmanager" "wheel" ];
description = "Jordan Holt";
useDefaultShell = true;
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILVHTjsyMIV4THNw6yz0OxAxGnC+41gX72UrPqTzR+OS jordan@vimium.com"
];
home = "/home/${name}";
group = "users";
uid = 1000;
};
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
@ -51,7 +56,6 @@ with lib.my;
file = mkAliasDefinitions options.home.file;
stateVersion = config.system.stateVersion;
};
home.packages = mkAliasDefinitions options.home.packages;
programs = mkAliasDefinitions options.home.programs;
services = mkAliasDefinitions options.home.services;
xdg = {
@ -59,11 +63,16 @@ with lib.my;
configFile = mkAliasDefinitions options.home.configFile;
dataFile = mkAliasDefinitions options.home.dataFile;
};
dconf.settings = mkAliasDefinitions options.dconf.settings;
};
};
users.users.${config.user.name} = mkAliasDefinitions options.user;
nixpkgs.config.allowUnfree = true;
environment.extraInit =
concatStringsSep "\n"
(mapAttrsToList (n: v: "export ${n}=\"${v}\"") config.env);
};
}
}