summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorMinijackson <minijackson@riseup.net>2025-02-25 12:06:07 +0100
committerMinijackson <minijackson@riseup.net>2025-02-25 16:38:59 +0100
commita80d9e8a8492d671582dc919102ac60d5413bb4c (patch)
treea8726790079fee3957c98914cfa1ab46c5d09151 /common
parentfd1712ede896e43e70676290ffea5a927b8962a4 (diff)
downloadnixos-config-reborn-a80d9e8a8492d671582dc919102ac60d5413bb4c.tar.gz
nixos-config-reborn-a80d9e8a8492d671582dc919102ac60d5413bb4c.zip
common/git: better configuration
Diffstat (limited to 'common')
-rw-r--r--common/commandline/git.nix33
1 files changed, 30 insertions, 3 deletions
diff --git a/common/commandline/git.nix b/common/commandline/git.nix
index 05785ed..397a76c 100644
--- a/common/commandline/git.nix
+++ b/common/commandline/git.nix
@@ -31,7 +31,11 @@ _inputs:
31 deltaCommand = "${pkgs.gitAndTools.delta}/bin/delta"; 31 deltaCommand = "${pkgs.gitAndTools.delta}/bin/delta";
32 in 32 in
33 { 33 {
34 init.defaultBranch = "master"; 34 init.defaultBranch = "main";
35
36 column.ui = "auto";
37 branch.sort = "-committerdate";
38 tag.sort = "version:refname";
35 39
36 color = { 40 color = {
37 branch = { 41 branch = {
@@ -59,11 +63,34 @@ _inputs:
59 algorithm = "histogram"; 63 algorithm = "histogram";
60 colormoved = "default"; 64 colormoved = "default";
61 colorMovedWS = "allow-indentation-change"; 65 colorMovedWS = "allow-indentation-change";
66 mnemonicPrefix = true;
62 }; 67 };
63 68
64 pull.ff = "only"; 69 fetch = {
70 all = true;
71 prune = true;
72 pruneTags = true;
73 };
74 pull = {
75 ff = "only";
76 rebase = true;
77 };
78 push = {
79 default = "simple";
80 autoSetupRemote = true;
81 };
65 82
66 rerere.enable = true; 83 help.autocorrect = "prompt";
84
85 rebase = {
86 autoSquash = true;
87 autoStash = true;
88 updateRefs = true;
89 };
90 rerere = {
91 enable = true;
92 autoUpdate = true;
93 };
67 94
68 merge = { 95 merge = {
69 conflictStyle = "zdiff3"; 96 conflictStyle = "zdiff3";