2023-07-07 21:25:05 +02:00
|
|
|
{ pkgs, ... }: {
|
2023-01-10 02:38:06 +01:00
|
|
|
programs.git = {
|
|
|
|
enable = true;
|
|
|
|
package = pkgs.gitFull;
|
|
|
|
|
|
|
|
userName = "Matei Adriel";
|
|
|
|
userEmail = "rafaeladriel11@gmail.com";
|
|
|
|
|
2023-07-07 21:25:05 +02:00
|
|
|
ignores = [
|
|
|
|
# Syncthing
|
|
|
|
".stfolder"
|
|
|
|
".stversions"
|
2023-09-22 18:37:24 +02:00
|
|
|
|
2023-08-17 09:31:46 +02:00
|
|
|
# Direnv
|
|
|
|
".direnv"
|
2023-09-22 18:37:24 +02:00
|
|
|
".envrc"
|
2023-07-07 21:25:05 +02:00
|
|
|
];
|
|
|
|
|
2023-09-22 18:37:24 +02:00
|
|
|
aliases = {
|
|
|
|
# Print history nicely
|
|
|
|
graph = "log --decorate --oneline --graph";
|
|
|
|
|
|
|
|
# Print last commit's hash
|
|
|
|
hash = "log -1 --format='%H'";
|
|
|
|
};
|
|
|
|
|
2023-01-10 02:38:06 +01:00
|
|
|
extraConfig = {
|
|
|
|
github.user = "Mateiadrielrafael";
|
|
|
|
hub.protocol = "ssh";
|
|
|
|
core.editor = "nvim";
|
2023-03-31 19:45:20 +02:00
|
|
|
init.defaultBranch = "main";
|
2023-09-22 18:37:24 +02:00
|
|
|
rebase.autoStash = true;
|
2023-01-10 20:39:33 +01:00
|
|
|
|
|
|
|
# Sign commits using ssh
|
|
|
|
gpg.format = "ssh";
|
|
|
|
user.signingkey = "~/.ssh/id_ed25519.pub";
|
|
|
|
|
2023-02-09 06:59:58 +01:00
|
|
|
# Sign everything by default
|
2023-01-10 20:39:33 +01:00
|
|
|
commit.gpgsign = true;
|
|
|
|
tag.gpgsign = true;
|
2023-01-10 02:38:06 +01:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-01-10 20:39:33 +01:00
|
|
|
# Github cli
|
|
|
|
programs.gh = {
|
|
|
|
enable = true;
|
|
|
|
settings.git_protocol = "ssh";
|
|
|
|
};
|
2023-01-10 02:38:06 +01:00
|
|
|
}
|