我已将 Git 的寻呼机选项设置为此
[pager]
log = diff-highlight
我从 Git's repository 3dbfe2b8
下载了 diff-highlight
脚本并将其放在我的 ~/bin
文件夹中。
$ where git
C:\Program Files\Git\cmd\git.exe
$ where diff-highlight
C:\Users\andy\bin\diff-highlight
运行 git log
会导致以下错误:
$ git log
Can't open diff-highlight: No such file or directory at C:\Users\andy\bin\diff-highlight line 36.
Segmentation fault
另一方面,下面的命令运行得很好,
$ git log -p --color | diff-highlight | less -FRSX
这意味着 diff-highlight
可以从 $PATH
获得,但是 Git 的配置找不到它。
我的 Git 版本是 2.12.0.windows.1
。
最佳答案
Recent guidance建议将整个 diff-highlight | less -FRSX
字符串到 pager.XXX
配置中。
虽然我只将它用于 pager.diff
和 interactive.diffFilter
。
关于windows - 设置为 diff-highlight 的 Git 寻呼机在 Windows 10 中不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42692840/