refactor: centralize host and user metadata

This commit is contained in:
2026-04-21 12:12:43 +02:00
parent 5cfd4d01c8
commit 6332c96d3e
33 changed files with 805 additions and 479 deletions
+13 -1
View File
@@ -1,7 +1,15 @@
{ ... }:
{
flake.modules.homeManager.git =
{ ... }:
{
config,
lib,
...
}:
let
user = config.meta.user;
primaryEmail = builtins.head (lib.filter (email: email.primary) (builtins.attrValues user.emails));
in
{
programs.git = {
enable = true;
@@ -12,6 +20,10 @@
];
settings = {
init.defaultBranch = "main";
user = {
name = user.realName;
email = primaryEmail.address;
};
};
};
};