about summary refs log tree commit diff
path: root/programs/git.nix
blob: f773a82c922c749d985b25f1429855b7ae7fcef4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
{
  programs.git = {
    enable = true;
    userName = "Patryk Niedźwiedziński";
    userEmail = "pniedzwiedzinski19@gmail.com";
    signing = {
      key = "pniedzwiedzinski19@gmail.com";
      signByDefault = true;
    };
    aliases = {
      lg = "log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative";
    };

    extraConfig = {
      url."ssh://git@github.com/".insteadOf = "https://github.com/";
      url."ssh://git@gitlab.com/".insteadOf = "https://gitlab.com/";
      url."ssh://git@bitbucket.org/".insteadOf = "https://bitbucket.org/";
    };
  };
}