nixos/modules/home/git.nix
Jake Hillion d9233021c7
All checks were successful
flake / flake (push) Successful in 2m9s
add enable options for modules/common/default
2024-04-27 13:46:06 +01:00

32 lines
609 B
Nix

{ pkgs, lib, config, ... }:
let
cfg = config.custom.home.git;
in
{
options.custom.home.git = {
enable = lib.mkEnableOption "git";
};
config = lib.mkIf cfg.enable {
home-manager.users.jake.programs.git = lib.mkIf (config.custom.user == "jake") {
enable = true;
extraConfig = {
user = {
email = "jake@hillion.co.uk";
name = "Jake Hillion";
};
pull = {
rebase = true;
};
merge = {
conflictstyle = "diff3";
};
init = {
defaultBranch = "main";
};
};
};
};
}