home: git: use diff-highlight in interactive diffs
Now even `git log -p` and `git add -p` can use the more readable diffs.
This commit is contained in:
parent
d86ff6192c
commit
48a9f9b11e
|
@ -3,6 +3,7 @@ let
|
||||||
cfg = config.my.home.git;
|
cfg = config.my.home.git;
|
||||||
|
|
||||||
inherit (lib.my) mkMailAddress;
|
inherit (lib.my) mkMailAddress;
|
||||||
|
diff-highlight = "${pkgs.gitAndTools.gitFull}/share/git/contrib/diff-highlight/diff-highlight";
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.my.home.git = with lib.my; {
|
options.my.home.git = with lib.my; {
|
||||||
|
@ -99,11 +100,11 @@ in
|
||||||
defaultBranch = "main";
|
defaultBranch = "main";
|
||||||
};
|
};
|
||||||
|
|
||||||
pager =
|
interactive = {
|
||||||
let
|
diffFilter = "${diff-highlight}";
|
||||||
diff-highlight = "${pkgs.gitAndTools.gitFull}/share/git/contrib/diff-highlight/diff-highlight";
|
};
|
||||||
in
|
|
||||||
{
|
pager = {
|
||||||
diff = "${diff-highlight} | less";
|
diff = "${diff-highlight} | less";
|
||||||
log = "${diff-highlight} | less";
|
log = "${diff-highlight} | less";
|
||||||
show = "${diff-highlight} | less";
|
show = "${diff-highlight} | less";
|
||||||
|
|
Loading…
Reference in a new issue