feat(git): add git module, set user config

This commit is contained in:
Mohammad Rafiq 2025-07-07 09:47:46 +08:00
parent a71cbb544a
commit f78770d4f1
No known key found for this signature in database
5 changed files with 15 additions and 2 deletions

12
nix/modules/git.nix Normal file
View file

@ -0,0 +1,12 @@
{
flake.modules.homeManager.default =
{ manifest, config, ... }:
{
home.sessionVariables.GIT_CONFIG_GLOBAL = "$HOME/.config/git/config";
programs.git = {
userName = manifest.users.${config.home.username}.name;
userEmail = manifest.users.${config.home.username}.email;
signing.key = "~/.ssh/id_ed25519.pub";
};
};
}