dotfiles.nix/home/git.nix

40 lines
666 B
Nix

{ flake, ... }:
let
inherit (flake.config.users) me';
in
{
programs.git = {
enable = true;
userEmail = me'.email;
userName = me'.name;
extraConfig = {
help.autocorrect = "prompt";
init.defaultBranch = "main";
pull.rebase = true;
# recommended by delta
diff.colorMoved = "default";
merge.conflictStyle = "diff3";
};
ignores = [
".DS_Store"
".direnv"
"result"
];
# enhanced diffs
# TODO: fix light colorscheme
delta = {
enable = true;
options = {
navigate = true;
line-numbers = true;
side-by-side = true;
};
};
};
}