cleanup: laptop back alive!!! so time to actually start configuring

This commit is contained in:
Evar 2025-01-17 21:51:20 -05:00
parent a14eff461b
commit 05d7340746
10 changed files with 131 additions and 368 deletions

53
home/git.nix Normal file
View file

@ -0,0 +1,53 @@
{
config,
options,
pkgs,
...
}: {
programs.git = {
enable = true;
delta = {
enable = true;
options = {
side-by-side = true;
};
};
# WISH: Figure out difftastic
# difftastic.enable = true;
# https://difftastic.wilfred.me.uk/git.html
# https://tsdh.org/posts/2022-08-01-difftastic-diffing-with-magit.html
userEmail = "git@evar.dev";
userName = "Evar";
extraConfig = {
init.defaultBranch = "main";
# Consider https://jvns.ca/blog/2024/02/16/popular-git-config-options/#pull-ff-only-or-pull-rebase-true
# Make merge conflicts more readable
merge.conflictstyle = "zdiff3";
rebase.autosquash = true;
rebase.autostash = true;
# Consider https://jvns.ca/blog/2024/02/16/popular-git-config-options/#push-default-simple-push-default-current-push-autosetupremote-true
# Add whole commit diff in text editor when writing commit message
#commit.verbose = true;
# Remember how merge conflicts were resolved to restore later
rerere.enabled = true;
# Better diffs
diff.algorithm = "histogram";
status.submoduleSummary = true;
diff.submodule = "log";
submodule.recurse = true;
merge.keepbackup = false;
#merge.tool = "${pkgs.meld}/bin/meld";
};
};
}