Setup git config for minion@greylag
Previously I didn't have any additional git tools enabled, this commit
adds git-review so I can push to gerrit, and delta so I can see my
diffs more beautifully. As I'm using Latte I've also fixed delta
colors for it, and I've removed the hardcoding of the username in git
config
Change-Id: Ieec0caad5b902d44f33259af9f1053ad1fc89552
Reviewed-on: https://git.clicks.codes/c/Chimera/NixFiles/+/391
Reviewed-by: Samuel Shuert <coded@clicks.codes>
Tested-by: Skyler Grey <minion@clicks.codes>
diff --git a/homes/x86_64-linux/minion@greylag/default.nix b/homes/x86_64-linux/minion@greylag/default.nix
index 1946998..1affb66 100644
--- a/homes/x86_64-linux/minion@greylag/default.nix
+++ b/homes/x86_64-linux/minion@greylag/default.nix
@@ -85,5 +85,11 @@
};
input.mouse.scrolling.natural = true;
+
+ git = {
+ delta.enable = true;
+ gitReview.enable = true;
+ auth.clicksUsername = "minion";
+ };
};
}
diff --git a/modules/home/git/default.nix b/modules/home/git/default.nix
index 6a161ea..8f91720 100644
--- a/modules/home/git/default.nix
+++ b/modules/home/git/default.nix
@@ -29,7 +29,10 @@
programs.git = {
enable = true;
- delta.enable = config.chimera.git.delta.enable;
+ delta = {
+ enable = config.chimera.git.delta.enable;
+ options.light = lib.mkIf config.chimera.theme.catppuccin.enable (config.chimera.theme.catppuccin.style == "Latte");
+ };
extraConfig = {
init.defaultBranch = "main";
@@ -55,7 +58,7 @@
};
url = {
"ssh://git@github.com/".pushInsteadOf = "https://github.com/";
- "ssh://minion@ssh.clicks.codes:29418/".pushInsteadOf = "https://git.clicks.codes/";
+ "ssh://${config.chimera.git.auth.clicksUsername}@ssh.clicks.codes:29418/".pushInsteadOf = "https://git.clicks.codes/";
};
merge.conflictstyle = "diff3";
trailer.ifexists = "addIfDifferent";