nixcfg/modules/darwin/home/default.nix
Harald Hoyer 47cf44ccfd refactor: improve formatting in Nextcloud and home config
Reformatted code blocks for better readability and consistency in Nextcloud and Darwin home configurations. No functional changes were made, ensuring existing behavior remains intact.
2024-12-13 09:19:09 +01:00

49 lines
1.2 KiB
Nix

{
options,
config,
pkgs,
lib,
inputs,
...
}:
with lib;
with lib.metacfg;
let
cfg = config.metacfg.home;
in
{
# imports = with inputs; [
# home-manager.darwinModules.home-manager
# ];
options.metacfg.home = with types; {
file = mkOpt attrs { } "A set of files to be managed by home-manager's <option>home.file</option>.";
configFile =
mkOpt attrs { }
"A set of files to be managed by home-manager's <option>xdg.configFile</option>.";
extraOptions = mkOpt attrs { } "Options to pass directly to home-manager.";
homeConfig = mkOpt attrs { } "Final config for home-manager.";
};
config = {
metacfg.home.extraOptions = {
home.stateVersion = mkDefault "23.11";
home.file = mkAliasDefinitions options.metacfg.home.file;
xdg.enable = true;
xdg.configFile = mkAliasDefinitions options.metacfg.home.configFile;
};
snowfallorg.users.${config.metacfg.user.name}.home.config =
mkAliasDefinitions options.metacfg.home.extraOptions;
home-manager = {
useUserPackages = true;
useGlobalPkgs = true;
# users.${config.metacfg.user.name} = args:
# mkAliasDefinitions options.metacfg.home.extraOptions;
};
};
}